JBoss 监控/分析
我有一个遗留的 JBoss 4.0.4/EJB 2.1/PostgreSQL 系统,其中有无数的“事务脚本化”过程作为服务器 EJB 方法,并且由于不良的编程实践(例如每次创建临时表, ETC)。
我是否可以在 JBoss(类似 Aspect)中插入一些东西来监视远程 EJB 方法的执行,捕获开始时间和结束时间,以便稍后进行进一步分析? 这个想法是尽可能优化系统中执行次数最多的方法,然后研究新平台的替代方案。
I have a legacy JBoss 4.0.4/EJB 2.1/PostgreSQL system with zillions of "transaction scripted" procedures as server EJB methods, and many of them have very slow and clumsy execution times due to bad programming practices (like creating temporary tables everytime, etc).
Is there something I can plug in JBoss (Aspect-Like) to monitor the executions of remote EJB methods, capturing start time, and end-time, for further profiling later? The idea is to optimize the most executed methods in the system as much as possible, and then investigate alternatives for a new platform.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
JBoss 发布所有已部署 EJB 的 JSR-77 统计数据。 它们可以通过 JMX 访问。 请参阅 JavaDoc:javax.management.j2ee.statistics.EJBStats 统计信息将包括调用次数和总执行时间,并且可以得出平均执行时间。 使用 JMX 监视器来获取数据。
JBoss publishes JSR-77 statistics for all deployed EJBs. They are accessible through JMX. See the JavaDoc for: javax.management.j2ee.statistics.EJBStats The stats will include the number of invocations and total elapsed execution time, and average execution time can be derived. The use a JMX monitor to acquire the data.
这看起来是一个很有前途的解决方案: http://www.jboss.org/jbossprofiler/
它不是完全是一个 AOP 解决方案,但看起来它的设置相当简单,并且会为您提供您正在寻找的数据。
This looks like a promising solution: http://www.jboss.org/jbossprofiler/
It's not exactly an AOP solution, but it appears it would be fairly simple to set up, and would give you the data you're looking for.