Optimize Java EE 8

Eclipse MicroProfile 3.1 updates Health and Metrics APIs

Sarah Schlothauer
© Shutterstock / smolav

Let us welcome the newest release from Eclipse MicroProfile. This time, MicroProfile 3.1 makes changes to the Metrics and Health API, adding a new feature set and more functionality for enterprise Java microservices. Check in and see what’s new for the third quarterly release and what the benefits of 3.1 are.

The Eclipse MicroProfile project helps optimize Enterprise Java for the microservices architecture. With support from Red Hat, IBM, Payara, and Tomitribe, Eclipse Microprofile continues improving upon Java innovation. (It even won the 2018 Duke’s Choice Award!) Its active community and forum work hard on new releases, so let’s have a look at the latest offerings.

MicroProfile 3.1 is the newest version and marks the 11th platform release for the project and is the third quarterly release.

Note: This release, like all 3.x releases, is based on Java EE 8. (Since Jakarta EE 8 has the same functions as Java EE 8, it is compatible with Jakarta EE 8 as well.) Users dependent on Java EE 7 should look at version 1.4 instead.

This version includes updates to the Health and Metrics APIs. Let’s take a look at the updates and new features.

eclipse microprofile

New updates to Metrics and Health APIs. Source.

Health 2.1 updates

MicroProfile Health, according to its GitHub README, uses health checks to “probe the state of a computing node from another machine (i.e. Kubernetes service controller) with the primary target being cloud infrastructure environments where automated processes maintain the state of computing nodes”.

Updates made to the Health API:

  • New method for creating responses
  • New config property allows for disabling Health Check procedures
  • Improved Javadoc
  • Tested the JSON format
  • Added delayed test
  • Test names have been added before each test
  • Removed duplicate Arquillian import
  • Removed EL API transitive dependency

Metrics 2.1 updates

MicroProfile Metrics is a specification that allows for MicroProfile servers to export Monitoring data to management agents. You can use it to expose your telemetry data.

SEE ALSO: 9 productive tips for hiring expert Java developers

Updates made to the Metrics API include:

  • Metric registry implementations are required to be thread-safe
  • Clarified API code that Gauges must return values that extend java.lang.Number.
  • Updates TCKs, now use RestAssured 4.0
  • Added the reusable(boolean) method for MetadataBuilder
  • For JSON export of scopes without metrics, implementations can omit them, or they can be presented with an empty value
  • New text to the specification about programmatic creation of metrics without annotations

Read more about all the new updates in this post by Cesar Saavedra.

Keeping up with MicroProfile

MicroProfile recently made headlines in the summer of 2019 regarding the future of Jakarta EE and Eclipse Microprofile.

SEE ALSO: New JAX Mag issue: Java 13 – the JDK’s hidden treasures

Are you caught up with the reports? Check out our interview with Sebastian Daschner, Java Champion and Lead Java Development Advocate for IBM about the new relationship that aims to simplify the development of Java EE apps for cloud and microservice contexts.

Grab the new version by following the instructions on GitHub.

Sarah Schlothauer

Sarah Schlothauer

All Posts by Sarah Schlothauer

Sarah Schlothauer is the editor for She received her Bachelor's degree from Monmouth University, West Long Branch, New Jersey. She currently lives in Frankfurt, Germany with her husband and cat where she enjoys reading, writing, and medieval reenactment. She is also the editor for Conditio Humana, an online magazine about ethics, AI, and technology.

Inline Feedbacks
View all comments