Class AuthenticationUserEventPublisher
java.lang.Object
net.solarnetwork.central.security.service.AuthenticationUserEventPublisher
Service for publishing user events from authentication events.
-
Constructor Summary
ConstructorsConstructorDescriptionAuthenticationUserEventPublisher(String context, UserEventAppenderBiz userEventAppenderBiz) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionbooleanGet the publish failure events only setting.voidprocessAuthenticationEvent(org.springframework.security.authentication.event.AbstractAuthenticationEvent event) Process authentication events.voidsetFailureOnly(boolean failureOnly) Set the publish failure events only setting
-
Constructor Details
-
AuthenticationUserEventPublisher
Constructor.- Parameters:
context- the top-level event context, such as the application name, to use in the generated event tagsuserEventAppenderBiz- the appender- Throws:
IllegalArgumentException- if any argument is null
-
-
Method Details
-
processAuthenticationEvent
@EventListener(org.springframework.security.authentication.event.AbstractAuthenticationEvent.class) public void processAuthenticationEvent(org.springframework.security.authentication.event.AbstractAuthenticationEvent event) Process authentication events.- Parameters:
event- the event to process
-
isFailureOnly
public boolean isFailureOnly()Get the publish failure events only setting.- Returns:
- true to publish failure events only
-
setFailureOnly
public void setFailureOnly(boolean failureOnly) Set the publish failure events only setting- Parameters:
failureOnly- true to publish failure events only
-