Class KeycloakSessionUtil

java.lang.Object
org.keycloak.utils.KeycloakSessionUtil

public class KeycloakSessionUtil extends Object
  • Method Details

    • getKeycloakSession

      public static KeycloakSession getKeycloakSession()
      Get the KeycloakSession currently associated with the thread.
      Returns:
      the current session
    • setKeycloakSession

      public static KeycloakSession setKeycloakSession(KeycloakSession session)
      Associate the KeycloakSession with the current thread.
      Warning: should not be called directly. Keycloak will manage this.
      Parameters:
      session -
      Returns:
      the existing KeycloakSession or null