Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

how to increase session time out  RSS feed

 
Vijay Kumar
Ranch Hand
Posts: 260
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi....
all......
I am indulge in a project in which my session time out is 30 sece &
but my db query takes 30 sec to execute . for this reason I want to increase my session time only for this qury.. how can I do this..
thankx
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Add a session-timeout entry to your web.xml file.
<session-timeout>30</session-timeout>
 
Vijay Kumar
Ranch Hand
Posts: 260
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi.ben
thankx for it

I know this but this session time will be constant I just want to increase session time during the run ime . when my query is going to execute.

thankx
 
Vijay Kumar
Ranch Hand
Posts: 260
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi.ben
thankx for it

I know this but this session time will be constant I just want to increase session time during the run ime . when my query is going to execute.

thankx
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A casual examination of the HttpSession JavaDocs reveals the methods:
setMaxInactiveInterval( seconds )
and
getMaxInactiveInterval()
These can be used to override the default set by web.xml on an individual session.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!