Interface LoginModuleMonitor
-
- All Superinterfaces:
Monitor<LoginModuleMonitor>
- All Known Implementing Classes:
LoginModuleStats
@ProviderType public interface LoginModuleMonitor extends Monitor<LoginModuleMonitor>
-
-
Field Summary
Fields Modifier and Type Field Description static LoginModuleMonitorNOOP
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default @NotNull java.lang.Class<LoginModuleMonitor>getMonitorClass()default @NotNull java.util.Map<java.lang.Object,java.lang.Object>getMonitorProperties()voidloginError()Event to be called in the case there is an error in the login chain.default voidloginFailed(@NotNull javax.security.auth.login.LoginException loginException, @Nullable Credentials credentials)Marks a failed login attempt for the givenCredentialsthat resulted in the givenLoginException.default voidprincipalsCollected(long timeTakenNanos, int numberOfPrincipals)Record the time taken to collect the given number of principals during the commit phase of a givenLoginModule.
-
-
-
Field Detail
-
NOOP
static final LoginModuleMonitor NOOP
-
-
Method Detail
-
loginError
void loginError()
Event to be called in the case there is an error in the login chain. This is not covering failed logins, but actual operational errors that probably need to be investigated. Any triggered event should have a corresponding error logged to make this investigation possible.- See Also:
loginFailed(LoginException, Credentials)
-
loginFailed
default void loginFailed(@NotNull @NotNull javax.security.auth.login.LoginException loginException, @Nullable @Nullable Credentials credentials)Marks a failed login attempt for the givenCredentialsthat resulted in the givenLoginException.- Parameters:
loginException- TheLoginExceptionraised by the failed login attempt.credentials- The credentials used for login.
-
principalsCollected
default void principalsCollected(long timeTakenNanos, int numberOfPrincipals)Record the time taken to collect the given number of principals during the commit phase of a givenLoginModule.- Parameters:
timeTakenNanos- The time in nanosecondsnumberOfPrincipals- The number of principals that were collected.
-
getMonitorClass
@NotNull default @NotNull java.lang.Class<LoginModuleMonitor> getMonitorClass()
- Specified by:
getMonitorClassin interfaceMonitor<LoginModuleMonitor>- Returns:
- The type to be passed to
Whiteboard.register(Class, Object, Map)
-
getMonitorProperties
@NotNull default @NotNull java.util.Map<java.lang.Object,java.lang.Object> getMonitorProperties()
- Specified by:
getMonitorPropertiesin interfaceMonitor<LoginModuleMonitor>- Returns:
- The properties to be passed to
Whiteboard.register(Class, Object, Map)
-
-