private final class KerberosServerEndpoint.ListenHandleImpl extends Object implements ServerEndpoint.ListenHandle
Modifier and Type | Field and Description |
---|---|
private int |
acceptFailureCount |
private long |
acceptFailureTime |
private boolean |
closed |
private Set |
connections |
private RequestDispatcher |
dispatcher |
(package private) KerberosServerEndpoint.ListenCookieImpl |
listenCookie
ListenCookie of the listen operation
|
private Object |
lock |
private SecurityContext |
securityContext
The security context at the time of the listen.
|
(package private) GSSCredential |
serverCred
The credential this server uses to authenticate itself
|
private KerberosKey |
serverKey
The Kerberos key used for server authentication
|
private ServerSocket |
serverSocket |
Constructor and Description |
---|
ListenHandleImpl(RequestDispatcher dispatcher,
KerberosKey serverKey,
GSSCredential serverCred,
ServerSocket serverSocket,
SecurityContext securityContext) |
Modifier and Type | Method and Description |
---|---|
private boolean |
checkKey()
Check whether the server key for this listen operation is
still valid and present in the server subject.
|
void |
close()
Close the server socket and all accepted connections
|
private boolean |
continueAfterAcceptFailure(Throwable t)
Throttles the accept loop after ServerSocket.accept throws
an exception, and decides whether to continue at all.
|
private void |
executeAcceptLoop()
Executes the accept loop.
|
ServerEndpoint.ListenCookie |
getCookie()
Returns a
ListenCookie to identify the listen
operation as the return value of the ListenContext.addListenEndpoint method. |
(package private) void |
remove(KerberosServerEndpoint.ServerConnectionImpl connection)
Remove a server connection from the connection list of this
listen operation.
|
(package private) void |
startAccepting()
Starts the accept loop.
|
String |
toString()
Returns a string representation of this listen handle.
|
private final RequestDispatcher dispatcher
private final SecurityContext securityContext
private KerberosKey serverKey
final GSSCredential serverCred
KerberosServerEndpoint.ListenCookieImpl listenCookie
private final ServerSocket serverSocket
private final Set connections
private final Object lock
private boolean closed
private long acceptFailureTime
private int acceptFailureCount
ListenHandleImpl(RequestDispatcher dispatcher, KerberosKey serverKey, GSSCredential serverCred, ServerSocket serverSocket, SecurityContext securityContext)
void startAccepting()
private void executeAcceptLoop()
public ServerEndpoint.ListenCookie getCookie()
ServerEndpoint.ListenHandle
ListenCookie
to identify the listen
operation as the return value of the ListenContext.addListenEndpoint
method.getCookie
in interface ServerEndpoint.ListenHandle
ListenCookie
to identify the listen
operationpublic void close()
close
in interface ServerEndpoint.ListenHandle
public String toString()
void remove(KerberosServerEndpoint.ServerConnectionImpl connection)
private boolean checkKey()
private boolean continueAfterAcceptFailure(Throwable t)
This method is copied from net.jini.jeri.tcp.TcpServerEndpoint.
Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.