Spring boot 普罗米修斯终点未暴露
我在SpringBoot应用程序中以以下方式添加了prometheus依赖项 我在gradle中添加了以下依赖项Spring boot 普罗米修斯终点未暴露,spring-boot,prometheus,spring-boot-actuator,Spring Boot,Prometheus,Spring Boot Actuator,我在SpringBoot应用程序中以以下方式添加了prometheus依赖项 我在gradle中添加了以下依赖项 runtimeOnly ('io.micrometer:micrometer-registry-prometheus') runtimeOnly ('io.micrometer:micrometer-core') application.yml management: endpoints.web.exposure.include: '*' endpoint.metrics.
runtimeOnly ('io.micrometer:micrometer-registry-prometheus')
runtimeOnly ('io.micrometer:micrometer-core')
application.yml
management:
endpoints.web.exposure.include: '*'
endpoint.metrics.enabled: true
endpoint.prometheus.enabled: true
metrics.export.prometheus.enabled: true
server.servlet.context-path: /route
部署文件中的注释
部署.yml
annotations:
prometheus.io/scrape: "true"
prometheus.io/probe: "true"
prometheus.io/port: "8010"
prometheus.io/path: "/actuator/prometheus"
部署后,未暴露/执行器/prometheus端点,但在localhost中暴露了该端点
我应该做什么改变才能让它工作