Add Java implementation links to metric model docs.

Change-Id: If2a36aa305a0806ffdf490f78e85afb71da8c202
This commit is contained in:
Julius Volz 2014-02-27 11:54:08 +01:00
parent 688f4f43c3
commit c35db9f080

View file

@ -50,6 +50,10 @@ A good example is of an elevator that tracks how many times it has been used in
its duty cycle. Each time someone hits the button to dispatch it, the elevator
can update its tally; and this is a tally it keeps!
See also the [counter Javadoc](https://github.com/prometheus/client_java/blob/master/client/src/main/java/io/prometheus/client/metrics/Counter.java)
in Prometheus' Java client library for further documentation and concrete code
examples.
## Gauges
A _Gauge_ reports instantaneous values based on external state. This is
@ -66,6 +70,10 @@ The following are good examples or applications of gauges:
Unlike a _Counter_, you don't have direct access to the events that brought the
_Gauge_ to its value today. This is a white-box and black-box distinction.
See also the [gauge Javadoc](https://github.com/prometheus/client_java/blob/master/client/src/main/java/io/prometheus/client/metrics/Gauge.java)
in Prometheus' Java client library for further documentation and concrete code
examples.
## Which to use: Counter or Gauge?
Knowing whether to use a _Counter_ or a _Gauge_ can be tough. Let's perform a
practical thought exercise. Below is an image of an automobile's instrument
@ -121,5 +129,9 @@ This is quite convenient, for if you are interested in tracking latencies of an
operation in real time, you get three types of information reported for free
with one metric.
See also the [summary Javadoc](https://github.com/prometheus/client_java/blob/master/client/src/main/java/io/prometheus/client/metrics/Summary.java)
in Prometheus' Java client library for further documentation and concrete code
examples.
# Acknowledgements
Robert Bray: Vehicle Instrument Panel