【发布时间】:2019-03-23 12:02:17
【问题描述】:
我有一个 SpringBoot 应用程序。 2.1.3.RELEASE由JWT担保,我想添加一个执行器。我添加了这个依赖
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
我已将此属性添加到 application.properties 文件中
management.endpoints.web.exposure.include=health,info
management.endpoint.health.show-details=always
当我访问/actuator 时,我收到了这样的回复:
{
"_links": {
"self": {
"href": "http://127.0.0.1:1133/tdk/actuator",
"templated": false
},
"health": {
"href": "http://127.0.0.1:1133/tdk/actuator/health",
"templated": false
},
"health-component": {
"href": "http://127.0.0.1:1133/tdk/actuator/health/{component}",
"templated": true
},
"health-component-instance": {
"href": "http://127.0.0.1:1133/tdk/actuator/health/{component}/{instance}",
"templated": true
},
"info": {
"href": "http://127.0.0.1:1133/tdk/actuator/info",
"templated": false
}
}
}
但是当我访问 http://127.0.0.1:1133/tdk/actuator/info 时,我只有
{}
【问题讨论】:
标签: spring rest spring-boot spring-mvc spring-boot-actuator