- Spring 5.0 Microservices(Second Edition)
- Rajesh R V
- 249字
- 2021-07-02 19:45:05
Spring Boot actuators for microservices instrumentation
The previous sections explored most of the Spring Boot features required for developing a microservices. In this section, we will explore some of the production-ready operational aspects of Spring Boot.
Spring Boot actuators provide an excellent out-of-the-box mechanism for monitoring and managing Spring Boot microservices in production.
Create another Spring starter project, and name it as chapter3.bootactuator.application; this time, select the Web, HAL browser, hateoas, and Actuator dependencies. Similar to chapter3.bootrest , add a GreeterController endpoint with the greet method. Add management.security.enabled=false to the application.properties file to grant access to all endpoints.
Do the following to execute the application:
- Start the application as Spring Boot App.
- Point the browser to localhost:8080/application. This will open the HAL browser. Review the Links section.
A number of links are available under the Links section. These are automatically exposed by the Spring Boot actuator:

Some of the important links are listed as follows:
- dump: Performs a thread dump and displays the result
- mappings: Displays a list of all the http request mappings
- info: Displays information about the application
- health: Displays the health condition of the application
- autoconfig: Displays the auto configuration report
- metrics: Shows different metrics collected from the application
From the browser, individual endpoints are accessible using /application/<endpoint_name>. For example, to access the /health endpoint, point the browser to localhost:8080/application/health.
- Cocos2d Cross-Platform Game Development Cookbook(Second Edition)
- The Android Game Developer's Handbook
- Java入門很輕松(微課超值版)
- Java從入門到精通(第4版)
- Learn Programming in Python with Cody Jackson
- Learning Firefox OS Application Development
- Python 3破冰人工智能:從入門到實戰
- Hands-On RESTful Web Services with Go
- 快人一步:系統性能提高之道
- Python Data Structures and Algorithms
- Linux Shell核心編程指南
- Android項目實戰:手機安全衛士開發案例解析
- Python語言實用教程
- 監控的藝術:云原生時代的監控框架
- 關系數據庫與SQL Server 2012(第3版)