Class AbstractSessionManager

    • Field Detail

      • DEFAULT_GLOBAL_SESSION_TIMEOUT

        public static final long DEFAULT_GLOBAL_SESSION_TIMEOUT
        Default main session timeout value, equal to 30 minutes.
        See Also:
        Constant Field Values
    • Constructor Detail

      • AbstractSessionManager

        public AbstractSessionManager()
    • Method Detail

      • getGlobalSessionTimeout

        public long getGlobalSessionTimeout()
        Returns the system-wide default time in milliseconds that any session may remain idle before expiring. This value is the main default for all sessions and may be overridden on a per-session basis by calling Subject.getSession().setTimeout(long) if so desired.
        • A negative return value means sessions never expire.
        • A non-negative return value (0 or greater) means session timeout will occur as expected.

        Unless overridden via the setGlobalSessionTimeout(long) method, the default value is DEFAULT_GLOBAL_SESSION_TIMEOUT.

        Returns:
        the time in milliseconds that any session may remain idle before expiring.
      • setGlobalSessionTimeout

        public void setGlobalSessionTimeout​(long globalSessionTimeout)
        Sets the system-wide default time in milliseconds that any session may remain idle before expiring. This value is the main default for all sessions and may be overridden on a per-session basis by calling Subject.getSession().setTimeout(long) if so desired.

        • A negative return value means sessions never expire.
        • A non-negative return value (0 or greater) means session timeout will occur as expected.

        Unless overridden by calling this method, the default value is DEFAULT_GLOBAL_SESSION_TIMEOUT.

        Parameters:
        globalSessionTimeout - the time in milliseconds that any session may remain idle before expiring.