Class NullSessionCache

  • All Implemented Interfaces:
    SessionCache, Container, Destroyable, Dumpable, Dumpable.DumpableContainer, LifeCycle

    @Deprecated(since="2021-05-27")
    public class NullSessionCache
    extends AbstractSessionCache
    Deprecated.
    The Eclipse Jetty and Apache Felix Http Jetty packages are no longer supported.
    NullSessionCache Does not actually cache any Session objects. Useful for testing. Also useful if you do not want to share Session objects with the same id between simultaneous requests: note that this means that context forwarding can't share the same id either.
    • Constructor Detail

      • NullSessionCache

        public NullSessionCache​(SessionHandler handler)
        Deprecated.
        Parameters:
        handler - The SessionHandler related to this SessionCache
    • Method Detail

      • shutdown

        public void shutdown()
        Deprecated.
      • doGet

        public Session doGet​(java.lang.String id)
        Deprecated.
      • doPutIfAbsent

        public Session doPutIfAbsent​(java.lang.String id,
                                     Session session)
        Deprecated.
      • doReplace

        public boolean doReplace​(java.lang.String id,
                                 Session oldValue,
                                 Session newValue)
        Deprecated.
      • doDelete

        public Session doDelete​(java.lang.String id)
        Deprecated.
        Description copied from class: AbstractSessionCache
        Remove the session with this identity from the store
        Specified by:
        doDelete in class AbstractSessionCache
        Parameters:
        id - the id
        Returns:
        Session that was removed or null
      • setEvictionPolicy

        public void setEvictionPolicy​(int evictionTimeout)
        Deprecated.
        Description copied from class: AbstractSessionCache
        -1 means we never evict inactive sessions. 0 means we evict a session after the last request for it exits >0 is the number of seconds after which we evict inactive sessions from the cache
        Specified by:
        setEvictionPolicy in interface SessionCache
        Overrides:
        setEvictionPolicy in class AbstractSessionCache
        Parameters:
        evictionTimeout - -1 is never evict; 0 is evict-on-exit; and any other positive value is the time in seconds that a session can be idle before it can be evicted.
        See Also:
        SessionCache.setEvictionPolicy(int)