Explain how to use spring boot admin to monitor spring cloud applications

The monitoring interfaces provided by spring boot, such as: / health, / info, etc. in fact, in addition to the previously mentioned information, there are other information industries that need to be monitored: the number of active sessions, the number of concurrent applications, latency, and other measurement information.

Recently, I was looking for a monitoring component of spring cloud, which requires granularity to each interface. Obviously, the hystrix dashboard is not suitable for this application scenario. Later, I found the artifact spring boot admin, which can be registered to Eureka and spring cloud for seamless integration. The page angularjs is fairly good, which contains many functions:

Well, not to mention, the code directly integrated with Eureka can monitor each service through the information in Eureka registry.

1. Build the Service Admin project, POM as follows:

2. Start main class:

3. Configuration file application properties:

4、logback. XML (implement log level modification function):

5. Start:

6. Note:

If you want to monitor the service registered with Eureka, you must introduce:

To enable some management functions, and a sentence must be added to the configuration file:

Turn off security authentication.

Code Hosting: https://github.com/Lovnx/micro-service

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>