Monitoring Spring Cloud Gateway
Collect and monitor the general performance metrics exposed by the SpringBoot actuator.
Pre-monitoring operations
If you want to monitor information in Spring Cloud Gateway with this monitoring type, you need to integrate your Spring Cloud Gateway application and enable the SpringBoot Actuator.
1、Add POM .XML dependencies:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
2. Modify the YML configuration exposure metric interface:
management:
endpoint:
gateway:
enabled: true
env:
show-values: ALWAYS
endpoints:
web:
exposure:
include: "*"