Acturator微服务监控端点

Posted 旺仔哥

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Acturator微服务监控端点相关的知识,希望对你有一定的参考价值。

一.添加依赖

 <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-actuator</artifactId>
 </dependency>

 

二.配置

server:
  port: 80
spring:
  application:
    name: order-service
eureka:
  client:
    service-url:
      defaultZone:
        http://localhost:8761/eureka/
management:
  endpoints:
    web:
      exposure:
        # include: "*" 开启所有端点
        include:
          - health
          - info
          - env
          - beans
          - shutdown #POST
  endpoint:
    health:
      show-details: always #显示完整的应用健康数据
    shutdown:
      enabled: true

 

 

 

以上是关于Acturator微服务监控端点的主要内容,如果未能解决你的问题,请参考以下文章

SpringBoot2.x系列教程(七十一)Spring Boot Actuator,每一个端点都有案例

SpringBoot2.x系列教程(七十一)Spring Boot Actuator,每一个端点都有案例

如何监视所有Spring Boot 微服务?

重学SpringBoot系列应用程序监控管理

微服务:啥是智能端点和哑管道?

在 NestJS 微服务中公开普通的 http 端点