是否有 属性 千分尺可以禁用发送 SFx 指标?

Is there a property in micrometer than can disable sending SFx metrics?

我正在开发一个 spring-boot 项目,该项目使用 SignalFx (APM) 进行监控,使用千分尺和执行器进行检测。
当我 运行 在本地申请时,即当我的个人资料设置为 local.
时,我不希望将指标发送到 SFx 是否有 属性 可用于禁用从本地发送的指标?
我有一个配置文件特定属性的工具。

查看 spring-boot-actuator-autoconfigure 模块中的 org.springframework.boot.actuate.autoconfigure.metrics.export.signalfx.SignalFxMetricsExportAutoConfiguration Available Here

这 class 加载与 SignalFx 相关的 bean。

仅当 属性: management.metrics.export.signalfx.enabled 具有值 true 或根本未定义时才加载。

因此,在本地配置文件中,您可以创建 application-local.properties 文件,其中将包含:

management.metrics.export.signalfx.enabled=false

当然,基于 yaml 的配置也是可能的。