监控与 j2se 应用程序的警报

发布于 2024-07-18 21:30:13 字数 229 浏览 8 评论 0原文

我正在设计一个 J2SE 应用程序,并寻找一个用于监视和警报的解决方案。 要求是:

  1. 对象可以报告其状态并在出现问题时发出警报。
  2. 对特定对象调用一些预定义的方法(例如转储其状态)。
  3. 监控 JVM 运行状况,尤其是内存使用情况。
  4. 最好从远程计算机访问以上所有内容。

最好的解决方案是什么? 有涉及 JMX 的吗?

I am designing a J2SE application, and looking for a solution for monitoring and alerts. The requirements are:

  1. Objects can report their status and issue alerts when they have problems.
  2. Calling some pre-defined methods on specific objects (e.g. to dump their state).
  3. Monitoring JVM health, especially memory usage.
  4. Preferably access all of the above from a remote computer.

What would be the best solution for that? Anything involving JMX?

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

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

发布评论

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

评论(7

九局 2024-07-25 21:30:13

如果您使用 Java 6u10 或更高版本,还可以参见 VisualVM(JDK 中的 jvisualvm.exe),它可以做各种有趣的事情,包括(通过插件)jconsole 可以做的相同事情。

确实非常适合检查。

If you use Java 6u10 or later, also see VisualVM (jvisualvm.exe in the JDK) which can do all kinds of interesting things, including (with a plugin) the same things jconsole can.

It is really great for inspecting.

想挽留 2024-07-25 21:30:13

是的,您描述的几乎是 JMX 和 MBean。

Yes, you're describing pretty much JMX and MBeans.

眉黛浅 2024-07-25 21:30:13

请参阅 JConsole,它随 Java 安装一起打包。 这允许您检查 JMX 可用的统计信息,无论是在本地还是远程计算机上。 您需要使用适当的选项启动受监控的虚拟机(在链接的文章中详细介绍),然后只需启动 JConsole 并指向所需的虚拟机(如果需要,可以通过身份验证进行保护)。

JConsole 可以检查所有标准 JMX bean,以及您创建/注册的任何 bean。 GUI 将允许您调用公开的方法、图表统计等。

See JConsole, which is packaged with the Java install. This allows you to inspect JMX-available statistics, whether on local or remote machines. You need to start up your monitored VM with the appropriate options (detailed in the linked article) and then simply start JConsole and point to the required VM (you can secure via authentication if you require).

JConsole can inspect all the standard JMX beans, plus any that you create/register. The GUI will allow you to call exposed methods, and chart statistics etc.

可可 2024-07-25 21:30:13

您可以使用 smartinspect 来记录应用程序中您想要的任何内容:对象、图片等您还可以从远程计算机访问它。

You can use smartinspect to can log whatever you want in your app: objects, pictures, etc. You can also have access to it from remote computers.

旧夏天 2024-07-25 21:30:13

如果您也想将警报加入其中,请查看 Jopr (http://www.jboss. org/jopr/

If you want to throw alerts into the mix too, have a look at Jopr (http://www.jboss.org/jopr/)

烟织青萝梦 2024-07-25 21:30:13

如果您想检查 JMX 数据,请尝试使用 JRockit Mission Control 附带的管理控制台。 它是 JConsole/VisualVM 的增强版。 检查数组、地图、集合、复合数据等并将监视的属性添加到图形或表盘中非常容易。 还可以创建触发警报。

您可以在此处免费下载。

替代文本 http:// www.oracle.com/technology/products/jrockit/missioncontrol/new_and_noteworthy/3.1.0/images/console/mbean_drilling.png

If you want to inspect JMX-data try the Management Console that comes with JRockit Mission Control. It's JConsole/VisualVM on steroids. It's very easy to inspect arrays, maps, Collections, compositeData etc., and add the monitored attributes to a graph or a dial. It's also possible to create trigger alerts.

You can download it here for free.

alt text http://www.oracle.com/technology/products/jrockit/missioncontrol/new_and_noteworthy/3.1.0/images/console/mbean_drilling.png

只为一人 2024-07-25 21:30:13

如果您需要持续监控解决方案,请考虑Evident ClearStone for Java。 通过此功能,您可以监控任何自定义 mbean,还可以将其设置为在违反阈值时向您发送警报。

If you need a continues monitoring solution, consider Evident ClearStone for Java. With this you can monitor any custom mbeans and also set it up to send you alerts when thresholds are breached.

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