gpt4 book ai didi

playframework - New Relic 未从 Play 2.2.1 Scala 应用程序收集数据

转载 作者:行者123 更新时间:2023-12-05 01:06:41 25 4
gpt4 key购买 nike

我正在尝试使用 New Relic's Java Agent 3.1.0 来监视基于 Scala 的 Play 2.2.1 Web 应用程序,但是 NR Web UI 似乎没有从我的服务器收集任何数据。

我已经验证了我的 newrelic.yml 配置文件是正确的,并且在使用以下命令启动应用程序时代理似乎按预期 Hook (根据官方说明 found here ):

root@myserver:/var/www/myapp/target/universal/myapp# ./bin/myapp -J-javaagent:/var/www/myapp/newrelic/newrelic.jar -Dnewrelic.bootstrap_classpath=true

Nov 4, 2013 18:15:41 +1100 NewRelic 1 INFO: Agent is using Logback
Nov 4, 2013 18:15:41 +1100 NewRelic 1 INFO: Loading configuration file "/var/www/myapp/newrelic/./newrelic.yml"
Play server process ID is 11599
[info] play - Application started (Prod)
[info] play - Listening for HTTP on /0:0:0:0:0:0:0:0:9000

运行上述程序后,我可以在 NR 的 Web UI 的应用程序部分中看到我的应用程序的名称,因此我的应用程序肯定在 ping 服务,但是我在仪表板中看不到任何实际数据。

我的 newrelic_agent.log 文件如下:
Nov 4, 2013 17:39:20 +1100 NewRelic 1 INFO: Writing to New Relic log file: /var/www/myapp/newrelic/logs/newrelic_agent.log
Nov 4, 2013 17:39:20 +1100 NewRelic 1 INFO: Agent Host: myserver IP: <snipped - it had my IP here!>
Nov 4, 2013 17:39:24 +1100 NewRelic 1 ERROR: com/caucho/vfs/WriteStream is marked as a weaved class, but no methods are matched to be weaved.
Nov 4, 2013 17:39:36 +1100 NewRelic 1 INFO: Configured to connect to New Relic at collector.newrelic.com:443
Nov 4, 2013 17:39:36 +1100 NewRelic 1 INFO: Setting audit_mode to false
Nov 4, 2013 17:39:36 +1100 NewRelic 1 INFO: Setting protocol to "https"
Nov 4, 2013 17:39:37 +1100 NewRelic 1 INFO: Configuration file is /var/www/myapp/newrelic/./newrelic.yml
Nov 4, 2013 17:39:37 +1100 NewRelic 1 INFO: New Relic Agent v3.1.0 has started
Nov 4, 2013 17:39:37 +1100 NewRelic 1 INFO: Java version: 1.7.0_45
Nov 4, 2013 17:39:37 +1100 NewRelic 1 INFO: The newrelic.bootstrap_classpath system property is deprecated.
Nov 4, 2013 17:39:37 +1100 NewRelic 1 INFO: Agent class loader is null which typically means the agent is loaded by the bootstrap class loader.
Nov 4, 2013 17:39:44 +1100 NewRelic 9 INFO: Collector redirection to collector-9.newrelic.com:443
Nov 4, 2013 17:39:45 +1100 NewRelic 9 INFO: Agent run id: 404659456
Nov 4, 2013 17:39:45 +1100 NewRelic 9 INFO: Agent 11288@myserver/My App connected to collector.newrelic.com:443
Nov 4, 2013 17:39:45 +1100 NewRelic 9 INFO: Real user monitoring is enabled with auto instrumentation for application "My App"
Nov 4, 2013 17:39:45 +1100 NewRelic 9 INFO: Errors will be sent to New Relic for Mealdrum

有人可以提供任何建议吗?谢谢!

最佳答案

虽然此日志显示干净的代理启动,但您可能是 3.1.0 代理问题的受害者,该问题干扰了 New Relic 对 Play 2 应用程序的检测。 Java Agent 3.1.1 解决了这个问题。发行说明位于文档站点:https://docs.newrelic.com/docs/releases/java

我最近注意到我们的文档站点上没有任何更新说明,但这很容易:替换你的 newrelic.jar 什么也不做,然后重新启动你的 JVM。

安装 3.1.1 并重新启动 JVM 后,指标应正确报告。如果没有,我会在 support.newrelic.com 上开一张票,这样我们就可以查看详细的日志。

关于playframework - New Relic 未从 Play 2.2.1 Scala 应用程序收集数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19763311/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com