?
Solved

Controlling of the session time out.

Posted on 2006-06-20
3
Medium Priority
?
188 Views
Last Modified: 2010-04-01
Hi, my application is running on Tomcat Application Server.

i have set my session in the web.xml like shown below.
   <session-config>
        <session-timeout>10</session-timeout>
    </session-config>

I am just wondering, can i change this session timeout on the fly, means on run time, user can able to change this time out from 10mins to another setting. Can it be done?

thanks.

0
Comment
Question by:spiderman19
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 3

Expert Comment

by:runa_paathak
ID: 16948489
Yes, use HttpSession.setMaxInactiveInterval(int interval)
This "Specifies the time, in seconds, between client requests before the servlet container will invalidate this session."
0
 

Author Comment

by:spiderman19
ID: 16949005
is this interval is in mins or seconds?

if i change like this, setting the setMacInactionInterval, is that means all the session within the system ( or in the system scope), it'll affec the rest ?
0
 
LVL 3

Accepted Solution

by:
runa_paathak earned 460 total points
ID: 16949074
No it is only for the current session. The interval needs to be given in seconds.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of the most important things in an application is the query performance. This article intends to give you good tips to improve the performance of your queries.
Are you looking for the options available for exporting EDB files to PST? You may be confused as they are different in different Exchange versions. Here, I will discuss some options available.
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question