如何从集群 Java 应用程序服务器记录到 syslog

发布于 2024-12-15 04:00:35 字数 272 浏览 4 评论 0原文

我的 Java EE 应用程序当前在 Glassfish 3 上运行,当前正在使用 java.util.logging 发送日志消息。该信息被 Glassfish 拦截并写入文件。

我想切换到集中式日志记录解决方案,因为应用程序将分布在集群中。

我有一个现有的系统日志基础设施。您对如何让应用程序登录到系统日志有什么建议吗? Glassfish的log-to-syslog功能没有文档,也没有配置,所以我没有考虑太多。

迁移到 SLF4J 并使用 SLF4J 系统日志附加器怎么样?

My Java EE application, which currently runs on Glassfish 3, is currently using java.util.logging to send logmessages. This is intercepted by Glassfish and written to files.

I'd like to switch to a centralised logging solution, since the application is going to be distributed in a cluster.

I have an existing syslog infrastructure. Do you have any suggestion, how to get the application to log to syslog? Glassfish's log-to-syslog feature has no documentation and no configuration, so I haven't considered it much.

What about migrating to SLF4J and using the SLF4J syslog appender?

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

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

发布评论

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

评论(1

惟欲睡 2024-12-22 04:00:35

请查看Glassfish to Syslog,其中展示了如何让 GlassFish 3 记录到系统日志/通过本地主机上的 UDP 514 发送系统日志。

Please have a look a look at Glassfish to Syslog which shows how to let GlassFish 3 log to system log/syslog via UDP 514 on localhost.

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