Spring Boot 应用程序的新 Relic 警报策略

发布于 2025-01-09 11:57:51 字数 277 浏览 3 评论 0原文

我正在使用 New Relic 千分尺库监控我的 Spring Boot 应用程序。指标显示良好。现在,我想为应用程序创建警报策略。在这里,对策略进行分类后,下一步是选择选项为空的实体。因此,我无法继续创建警报。

附加图像以供参考: 空实体

这是什么原因,如何解决?

I am monitoring my Spring Boot application using the New Relic micrometer library. The metrics are showing up fine. Now, I want to create an alert policy for the application. Here, after categorising the policy, the next step is selecting an entity for which the options are empty. Thus, I am not able to move forward with creating the alerts.

Attaching an image for reference: Empty entity

What is the reason for this and how to resolve it?

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

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

发布评论

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

评论(1

饮惑 2025-01-16 11:57:51

新的 Relic“应用程序”警报应用于应用程序/服务实体(请参阅过滤为“服务”的“资源管理器”选项卡)。为了确保微米遥测与“服务”相关联,请确保 SpringBoot 检测在 newRelicRegistryConfig 中包含应用程序的 serviceName

public class NewRelicMetricsExportAutoConfiguration {

  @Bean
  public NewRelicRegistryConfig newRelicConfig() {
    return new NewRelicRegistryConfig() {

      (...)
    
      @Override
      public String serviceName() {
        return "My Service Name";
      }

    };
  }

New Relic "Application" alerts are applied to the Application/Service entities (See your "Explorer" tab filtered to "Service"). In order to ensure that micrometer telemetry is associated with "Services" ensure that the SpringBoot instrumentation includes the serviceName of the application in the newRelicRegistryConfig.

public class NewRelicMetricsExportAutoConfiguration {

  @Bean
  public NewRelicRegistryConfig newRelicConfig() {
    return new NewRelicRegistryConfig() {

      (...)
    
      @Override
      public String serviceName() {
        return "My Service Name";
      }

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