Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to know the sessionID is alive ?

 
kwwong wong
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For example, when I get the sessionID from database and want to know the session is alive or not. How can I do?
 
Hartmut Ludwig
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by kwwong wong:
For example, when I get the sessionID from database and want to know the session is alive or not. How can I do?

Hi, Kwwong,
I just found out, how it works for Tomcat's Session Manager.
Using org.apache.catalina.session.ManagerBase you can call the method findSession(java.lang.String id) which returns the active Session with the specified session id if there is one otherwise it returns null.
sl
Hartmut
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic