How it works...

Spring Boot provides a library called actuator with features to help you monitor and manage the application when deployed to production. This out-of-the-box functionality doesn't require any setup from the developers' side. So you get auditing, health checks, and metrics-gathering all without any work.

As mentioned before, actuator uses Micrometer to instrument and capture different metrics from the code, such as:

  • JVM memory usage
  • Connection-pooling information
  • Response time of different HTTP endpoints in the app
  • Frequency of invocation of different HTTP endpoints

To enable your application to have these production-ready features, you need to add the following dependency to your pom.xml if you are using Maven (there is ...

Get Java 11 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.