How to set the session timeout never expires in struts1.x
web.xml
-------
<session-config>
<session-timeout>1440</session-timeout>
</session-config>
Set it to -1
<session-config>
<session-timeout>-1</session-timeout>
</session-config>
Warning:
This is not recommended to set session expiration infinite.
But, you should add the full details of why you are doing this, So that a proper solution you'l get.
try out this..
paste below code in your web.xml
<session-config>
<session-timeout>-1</session-timeout>
</session-config>
You can use "-1" where the session never expires. Since you do not know how much time it will take for the thread to complete.
Note : Please avoid to use infinite session timeout, it results to some memory leaks.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.