weblogic之 hogging thread & stuck thread

本文介绍了一个专门用于检测WebLogic 12c中死锁线程的小型应用程序。该应用通过创建忙碌或等待时间过长的线程来模拟卡住的情况,使用了简单的JSP页面设置参数,调用注入的状态less会话bean的异步业务方法。文章还探讨了hogging线程的概念及其在WebLogic中的表现。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

The application allows you to create threads which are busy or which are waiting long enough to be detected as “stuck” by WebLogic.

This little application will only work with WLS12c. I intentionally avoided JSF, so a plain JSP page is used to set your parameters. The JSP is calling a simple Servlet which in a for loop is calling an asynchronous business method of an injected stateless session bean. @Asynchronous and no-interface session beans are only available in EJB3.1 so you have to run it on WLS12c. Unlike in previous versions, the EJB is directly packaged into the .war file for deployment.

Depending on which method was called on the EJB is either waiting n seconds using Thread.sleep() or calculating some trigonometric function for n seconds. Both methods will cause stuck threads.


What are hogging threads? When do threads become hogged? After what period of time?

hogging_duration = scheduler 2 seconds , algorithm

转载于:https://my.oschina.net/u/864135/blog/1358751

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值