Class TeamAppsSessionManager

  • All Implemented Interfaces:
    jakarta.servlet.http.HttpSessionListener, java.util.EventListener

    public class TeamAppsSessionManager
    extends java.lang.Object
    implements jakarta.servlet.http.HttpSessionListener
    Implements a cache for UiSession instances.

    It takes care of the removal of timed-out sessions. The "last used" information is updated every time a session is retrieved.

    • Method Detail

      • getUiSessionById

        public UiSession getUiSessionById​(java.lang.String sessionId)
      • getSessionContextById

        public SessionContext getSessionContextById​(java.lang.String sessionId)
      • getNumberOfSessions

        public int getNumberOfSessions()
      • getNumberOfSessionsByState

        public int getNumberOfSessionsByState​(UiSessionState state)
      • getAllSessions

        public java.util.List<SessionPair> getAllSessions()
      • getBufferedCommandsCount

        public int getBufferedCommandsCount()
      • getUnconsumedCommandsCount

        public int getUnconsumedCommandsCount()
      • getNumberOfAvailableClosedSessionStatistics

        public int getNumberOfAvailableClosedSessionStatistics()
      • getClosedSessionsStatistics

        public java.util.List<UiSessionStats> getClosedSessionsStatistics()
      • initSession

        public void initSession​(java.lang.String sessionId,
                                org.teamapps.dto.UiClientInfo clientInfo,
                                jakarta.servlet.http.HttpSession httpSession,
                                int maxRequestedCommandId,
                                MessageSender messageSender)
      • sessionCreated

        public void sessionCreated​(jakarta.servlet.http.HttpSessionEvent se)
        Specified by:
        sessionCreated in interface jakarta.servlet.http.HttpSessionListener
      • updateSessionStates

        public void updateSessionStates()
      • destroy

        public void destroy()
      • createSessionContext

        public SessionContext createSessionContext​(UiSession uiSession,
                                                   org.teamapps.dto.UiClientInfo uiClientInfo,
                                                   jakarta.servlet.http.HttpSession httpSession,
                                                   java.lang.String navigationPathPrefix)