Tomcat Web 应用程序线程卡在服务阶段 - 导致应用程序挂起

发布于 2024-12-14 19:00:35 字数 758 浏览 4 评论 0原文

我们使用 Tomcat 6 / IIS 来托管 Java MVC Web 应用程序(Spring MVC 和 Frontman)。最近,当我们看到线程在服务阶段卡住几个小时时,我们开始遇到问题。
使用 Lambda Probe,我们看到线程开始堆积,最终应用程序变得无响应。处理时间增加,零字节输入或输出。该 URL 是可访问的,并且日志显示它已开始但从未结束。
<代码> IP 阶段处理时间 字节输入 字节输出 url
111.11.111.111 服务 00:57:26.0 0b 0b GET /应用程序/命令/监视器
所有这些都在测试服务器上进行,设置如下:
ISAPI 过滤器工作器:
<代码> worker.testuser.type=ajp13
worker.testuser.host=localhost
worker.testuser.port=8009
worker.testuser.socket_timeout=300
worker.testuser.connection_pool_timeout=600

服务器.xml:
<代码> < 连接器
端口=“8009” 协议=“AJP/1.3”
重定向端口=“8443”
tomcatAuthentication=“假”
连接超时=“6000”
>>
关于为什么会发生这种情况或者如何配置 Tomcat 来杀死古老的应用程序线程有什么想法吗?

We are using Tomcat 6 / IIS to host our Java MVC web applications (Spring MVC and Frontman). We started running into problems recently when we see threads stuck in the Service stage for hours.
Using Lambda Probe we see the threads start to pile up and eventually the app becomes unresponsive. The processing time increases, zero bytes in or out. The url is reachable and the logs show that it starts but never finishes.

IP Stage processing time bytes-in bytes-out url
111.11.111.111 Service 00:57:26.0 0b 0b GET /Application/command/monitor

All of this is on a test server set up as follows:
ISAPI filter worker:

worker.testuser.type=ajp13
worker.testuser.host=localhost
worker.testuser.port=8009
worker.testuser.socket_timeout=300
worker.testuser.connection_pool_timeout=600

Server.xml:

<
Connector
port="8009"
protocol="AJP/1.3"
redirectPort="8443"
tomcatAuthentication="false"
connectionTimeout="6000"
/>

Any thoughts on why this happens or how to configure Tomcat to kill ancient application threads?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

又爬满兰若 2024-12-21 19:00:35

可以使用 java 监视包获取所有线程和线程转储,并使用线程 id 终止(尽管不推荐使用线程停止,但它可以完成工作)

http://docs.oracle.com/javase/1.5.0/docs/guide/management/overview.html

Can use java monitoring package to get the all the thread and thread dumps and kill using the thread id (though thread stop is deprecated it does the work)

http://docs.oracle.com/javase/1.5.0/docs/guide/management/overview.html

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文