How do you create Http Session that never times out ?

Showing Answers 1 - 3 of 3 Answers

akantilal

  • Jun 12th, 2007
 

You can achieve this by setting a negative value for the max inactive interval for the session. Here is the code:

HttpSession session = request.getSession(true);
session.setMaxInactiveInterval(-1);

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions