普罗米修斯执行器的自定义路径 [英] custom path for prometheus actuator
问题描述
我目前正在尝试将我们的prometheus lib迁移到spring boot 2.0.3.RELEASE.
我们为普罗米修斯使用了一条自定义路径,到目前为止,我们一直在努力确保这一点.由于可能为信息端点和运行状况端点设置自定义路径,因此请使用management.endpoint.<health/info>.path
.
我尝试指定management.endpoint.prometheus.path
,但仍只能在/actuator/prometheus
下访问.
I am currently trying to migrate our prometheus lib to spring boot 2.0.3.RELEASE.
We use a custom path for prometheus and so far we use a work around to ensure this. As there is the possibility for a custom path for the info- and health-endpoint, uses management.endpoint.<health/info>.path
.
I tried to specify management.endpoint.prometheus.path
, but it was still just accessible under /actuator/prometheus
.
如何使用自定义路径或普罗米修斯?
How can I use a custom path or prometheus?
我们使用以下库(build.gradle的片段)启用prometheus
We enable prometheus using the following libs (snippet of our build.gradle)
compile "org.springframework.boot:spring-boot-starter-actuator:2.0.3.RELEASE"
compile "io.micrometer:micrometer-core:2.0.5"
compile "io.micrometer:micrometer-registry-prometheus:2.0.5"
我们还使用了PrometheusMetricsExportAutoConfiguration
我们非常感谢您的帮助:)
Your help is highly appreciated :)