用于Apache Tomcat的应用程序默认的会话超时 [英] default session timeout for Apache Tomcat applications
问题描述
什么是部署在Tomcat5.5中的Web应用程序的默认会话超时?它是针对特定浏览器?在我的Web应用程序的默认超时既不在web.xml中也没有在code提及。
What is the default session timeout for web applications deployed on Tomcat5.5 ? Is it browser specific? In my web applications default timeout is mentioned neither in web.xml nor in code.
推荐答案
打开TOMCAT_HOME / conf目录/ web.xml文件,找到这个
Open tomcat_home/conf/web.xml and find this
<!-- ==================== Default Session Configuration ================= -->
<!-- You can set the default session timeout (in minutes) for all newly -->
<!-- created sessions by modifying the value below. -->
<session-config>
<session-timeout>30</session-timeout>
</session-config>
所有的webapps隐式地从这个默认的Web描述符继承。您可以覆盖会话配置,以及在web.xml中定义的其他设置。
all webapps implicitly inherit from this default web descriptor. You can override session-config as well as other settings defined there in your web.xml.
这实际上是从我的Tomcat 7(Windows)中,但我认为5.5的conf也不是很不同的。
This is actually from my Tomcat 7 (Windows) but I think 5.5 conf is not very different
这篇关于用于Apache Tomcat的应用程序默认的会话超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!