用于Apache Tomcat的应用程序默认的会话超时 [英] default session timeout for Apache Tomcat applications

查看:399
本文介绍了用于Apache Tomcat的应用程序默认的会话超时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

什么是部署在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屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆