Note: Startup events are available from Spring Boot 2.4 M3
Configure Spring Boot application to collect startup events:
@SpringBootApplication
public class DemoApplication {
public static void main(String[] args) {
SpringApplication app = new SpringApplication(DemoApplication.class);
app.setApplicationStartup(new BufferingApplicationStartup(1000));
app.run(args);
}
}
Note: you must enable CORS on Actuator "startup" endpoint in application.properties
to analyze startup report through this website
management.endpoints.web.exposure.include=startup
management.endpoints.web.cors.allowed-origins=https://spring-boot-startup-analyzer.netlify.app
management.endpoints.web.cors.allowed-methods=GET,POST