O'Reilly logo

Hands-On Enterprise Java Microservices with Eclipse MicroProfile by Scott Stark, Antoine Sabot-Durand, Pavol Loffay, Jeff Mesnil, Heiko W. Rupp, Cesar Saavedra

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Gauges

A gauge is a metric whose value arbitrarily goes up and down. Gauges are always backed by a method that supplies the value of the gauge:

@Gaugeint provideGaugeValue() {  return 42;  // The value of the gauge is always 42}

The gauge's value is computed, like all other values, when a client requests the values. This requires the implementation of the gauge method to be very quick, so that a caller is not blocked.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required