What is Spring Boot Admin?
Spring Boot Admin is a Angular based application, developed on top of the Spring Actuator Endpoints. It allow us to monitor and manage the Spring Boot applications.How to setup Spring Boot Admin
- Create the simple spring boot project with https://start.spring.io/
- Add Spring Boot Admin Server and UI depedencies
- Add @EnableAdminServer in the Spring Boot Configuration
- Add Spring Boot Admin client dependency in the client application (the application which we need to monitor)
- Tell the client where to find the Spring Boot Admin Server , It can be done in two ways
- Static Configuration (add the below entry in application.properties)
- Discovery Client (Eureka) (not covered in this post)
<dependency>
<groupId>de.codecentric</groupId>
<artifactId>spring-boot-admin-server</artifactId>
<version>1.5.7</version>
</dependency>
<dependency>
<groupId>de.codecentric</groupId>
<artifactId>spring-boot-admin-server-ui</artifactId>
<version>1.5.7</version>
</dependency>
@Configuration
@EnableAutoConfiguration
@EnableAdminServer
public class SpringBootAdminApplication {
public static void main(String[] args) {
SpringApplication.run(Application.class, args);
}
}
<dependency>
<groupId>de.codecentric</groupId>
<artifactId>spring-boot-admin-starter-client</artifactId>
<version>1.5.7</version>
</dependency>
spring.boot.admin.url=http://localhost:1111
Sample Spring Boot Admin Project
The simple spring boot admin project can be available in github
Note: As of now the Spring Boot Admin is not compatible with Spring Boot 2
Comments
Post a Comment