Class AuthenticationInfoManager
java.lang.Object
com.levigo.jadice.web.transport.server.session.AuthenticationInfoManager
The manager holds all information about the connected clients and their provided authentication
information. With a given clientId the matching authentication information can be retrieved. If a
client was not seen for
ttl
the matching entry is
deleted. If a session was closed by the client side, the information is removed after
sessionClosedTTL
.-
Method Summary
Modifier and TypeMethodDescriptionvoid
authenticationInfoUpdated
(MessageContext messageContext, String authenticationInfo) Updates the information for the given clientvoid
authenticationInfoUpdated
(String clientId, String authenticationInfo) Updates the information for the given clientgetAuthenticationInfo
(String clientId) Retrieves the matching authentication information.static AuthenticationInfoManager
getTtl()
void
sessionClosed
(String cliendId) Sets the lifetime of the information to now +sessionClosedTTL
void
setSessionClosedTTL
(Duration sessionClosedTTL) void
void
Renews the lifetime of the matching authentication information.
-
Method Details
-
getInstance
-
touch
Renews the lifetime of the matching authentication information.- Parameters:
clientId
- The clientId for the authentication information.
-
getAuthenticationInfo
Retrieves the matching authentication information.- Parameters:
clientId
- The clientId to search the matching authentication information.- Returns:
- The authentication information or null if no information was found.
-
sessionClosed
Sets the lifetime of the information to now +sessionClosedTTL
- Parameters:
cliendId
- The clientId of the client whose session was closed.
-
authenticationInfoUpdated
Updates the information for the given client- Parameters:
messageContext
- The messageContext which contains the clientIdauthenticationInfo
- The new authentication information
-
authenticationInfoUpdated
Updates the information for the given client- Parameters:
clientId
- The clientIdauthenticationInfo
- The new authentication information
-
getTtl
-
setTtl
-
getSessionClosedTTL
-
setSessionClosedTTL
-