Class RequestAttributesBasedClientIdRetrievalStrategy

java.lang.Object
ubic.gemma.rest.analytics.ga4.RequestAttributesBasedClientIdRetrievalStrategy
All Implemented Interfaces:
ClientIdRetrievalStrategy

public class RequestAttributesBasedClientIdRetrievalStrategy extends Object implements ClientIdRetrievalStrategy
Strategy that retrieves and store client IDs in the RequestAttributes.
Author:
poirigui
See Also:
  • RequestContextHolder.currentRequestAttributes()
  • Constructor Details

    • RequestAttributesBasedClientIdRetrievalStrategy

      public RequestAttributesBasedClientIdRetrievalStrategy()
  • Method Details

    • get

      @Nullable public String get()
      Specified by:
      get in interface ClientIdRetrievalStrategy
    • setAttribute

      public void setAttribute(String attribute)
      Set the attribute to retrieve to obtain the client ID.
    • setScope

      public void setScope(int scope)
      Set the scope to use for retrieving and storing the client ID.
      See Also:
      • RequestAttributes.SCOPE_REQUEST
      • RequestAttributes.SCOPE_SESSION