Class RequestAuditContext

  • All Implemented Interfaces:
    Context

    public class RequestAuditContext
    extends AbstractContext
    A context for audit information for an incoming request.
    • Constructor Detail

      • RequestAuditContext

        public RequestAuditContext​(Context parent)
        Constructs a new context using the specified parent and the current time as the request received time.
        Parameters:
        parent - The parent context.
      • RequestAuditContext

        public RequestAuditContext​(Context parent,
                                   Clock clock)
        Constructs a new context using the specified parent and the current time as the request received time.
        Parameters:
        parent - The parent context.
        clock - The instance of Clock to use.
      • RequestAuditContext

        public RequestAuditContext​(JsonValue savedContext,
                                   ClassLoader classLoader)
        Restores a saved context.
        Parameters:
        savedContext - The saved state.
        classLoader - The ClassLoader to use.
    • Method Detail

      • getRequestReceivedTime

        public long getRequestReceivedTime()
        Get the time in milliseconds since the epoch that the request was received.
        Returns:
        The request received time.