springboot actuator
Posted 清浊
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了springboot actuator相关的知识,希望对你有一定的参考价值。
1、什么是actuator
线上监控工具
2、如何整合
遵循三板斧
第一步加依赖
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
第二步加注解
无
第三步加配置
无
启动后访问项目路径加上/actuator
/actuator/health,作用健康检查。
在配置中加入
management.endpoint.health.show-details=always
可以检查如下这么多资源的健康状态
53.8.1 Auto-configured HealthIndicators
Checks that a Cassandra database is up. |
|
Checks that a Couchbase cluster is up. |
|
Checks for low disk space. |
|
Checks that a connection to |
|
Checks that an Elasticsearch cluster is up. |
|
Checks that an InfluxDB server is up. |
|
Checks that a JMS broker is up. |
|
Checks that a mail server is up. |
|
Checks that a Mongo database is up. |
|
Checks that a Neo4j server is up. |
|
Checks that a Rabbit server is up. |
|
Checks that a Redis server is up. |
|
Checks that a Solr server is up. |
info端口主要是用来描叙应用信息的
info.app-name = pay
info.author = xiaofeiyang
info.email = 469821953@qq.com
actuator暴露的所有端点见
53.2 Exposing Endpoints
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
Yes |
|
N/A |
No |
|
Yes |
No |
|
Yes |
Yes |
|
Yes |
No |
|
N/A |
No |
|
N/A |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
N/A |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
|
Yes |
No |
以上是关于springboot actuator的主要内容,如果未能解决你的问题,请参考以下文章
springboot04_springboot特性之Actuator
#yyds干货盘点# springboot整合Actuator监控
springboot源码研究actuator,自定义actuator路径
[转]springboot 监控 Actuator和Admin