Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Session

 
S Raman
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

1)Is there any way to know how many session objects are there on the server side

2) how to make a session ivalid after 30 minutes of inactivity in tomcat

3) how do i call my database to update the user has been invalidated by inactivity (2)
I have a list of user logged in the system the user end is applet.
If the user is inactive for 30 mts the session should expire
If the session expires i need a entry in database for the same


thanks
 
asdf lkjh
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think you can specify the session timeout in web.xml as:

<web-app>
<session-config>
<session-timeout>60</session-timeout>
</session-config>

...
</web-app>
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65225
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"sush pop", you have previously been warned on one or more occasions regarding adjusting your display name to meet JavaRanch standards. This is not optional. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it prior to your next post.

Your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

Be aware that accounts with invalid display names are disabled.

bear
JavaRanch Sheriff
[ October 17, 2008: Message edited by: Bear Bibeault ]
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by S Raman:
Hi,

1)Is there any way to know how many session objects are there on the server side

2) how to make a session ivalid after 30 minutes of inactivity in tomcat

3) how do i call my database to update the user has been invalidated by inactivity (2)
I have a list of user logged in the system the user end is applet.
If the user is inactive for 30 mts the session should expire
If the session expires i need a entry in database for the same


thanks


1. HttpSessionListener help you

2. define in DD as pop explained you above

3. do logic about Database in destroyedSession() in HttpSessionListener

for detail google HttpSessionListener

Hope This Helps
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic