Class AccessTokenGeneratedEvent

java.lang.Object
java.util.EventObject
io.micronaut.context.event.ApplicationEvent
io.micronaut.security.token.event.AccessTokenGeneratedEvent
All Implemented Interfaces:
Serializable

public class AccessTokenGeneratedEvent extends io.micronaut.context.event.ApplicationEvent
Triggered when a JWT access token is generated.
Since:
1.0
Author:
Sergio del Amo
See Also:
  • Constructor Details

    • AccessTokenGeneratedEvent

      public AccessTokenGeneratedEvent(Object source)
      Triggered when a JWT access token is generated.
      Parameters:
      source - A String with the JWT access token generated.
      Throws:
      IllegalArgumentException - if source is null.
  • Method Details

    • toString

      public String toString()
      The string representation never includes the access token. Micronaut logs every published event at DEBUG using its string representation, so exposing it would write the access token to the log.
      Overrides:
      toString in class EventObject
      Returns:
      The string representation of the event with the access token redacted.
      Since:
      5.5.2