对于
Spring Boot
3.1.1 - 关于 Actuator,如果在 Web 浏览器中执行 /actuator
端点,则默认显示以下内容:
{
"_links": {
"self": {
"href": "http://localhost:8085/actuator",
"templated": false
},
"health": {
"href": "http://localhost:8085/actuator/health",
"templated": false
},
"health-path": {
"href": "http://localhost:8085/actuator/health/{*path}",
"templated": true
}
}
}
观察到每个路径/uri 总是出现
"templated": false
部分。顺便说一句,当其他端点也暴露时,它就会出现
问题
"templated": false
对于 Spring Boot Actuator 意味着什么?额外问题
true
?示例
{
"_links":{
"self":{
"href":"http://localhost:8080/actuator",
"templated":false
},
"health":{
"href":"http://localhost:8080/actuator/health",
"templated":false
},
"health-path":{
"href":"http://localhost:8080/actuator/health/{*path}",
"templated":true
}
}
}
其中
health-path
是模板化的:意思是,您可以指定您想要查看的详细信息。