public class NoOpMetricsRegistry extends java.lang.Object implements MetricsRegistry
MetricsRegistry
implementation for when no actual metrics need to be
recorded but a registry is still required.Constructor and Description |
---|
NoOpMetricsRegistry() |
Modifier and Type | Method and Description |
---|---|
Counter |
newCounter(java.lang.String group,
Counter counter)
Register existing
Counter with this registry |
Counter |
newCounter(java.lang.String group,
java.lang.String name)
Create and register a new
Counter |
<T> Gauge<T> |
newGauge(java.lang.String group,
Gauge<T> gauge)
Register an existing
Gauge |
<T> Gauge<T> |
newGauge(java.lang.String group,
java.lang.String name,
T value)
Create and register a new
Gauge |
public Counter newCounter(java.lang.String group, java.lang.String name)
MetricsRegistry
Counter
newCounter
in interface MetricsRegistry
group
- Group for this Countername
- Name of to-be-created Counterpublic Counter newCounter(java.lang.String group, Counter counter)
MetricsRegistry
Counter
with this registrynewCounter
in interface MetricsRegistry
group
- Group for this Countercounter
- Existing Counter to registerpublic <T> Gauge<T> newGauge(java.lang.String group, java.lang.String name, T value)
MetricsRegistry
Gauge
newGauge
in interface MetricsRegistry
T
- Type the Gauge will be wrappinggroup
- Group for this Gaugename
- Name of to-be-created Gaugevalue
- Initial value for the Gaugepublic <T> Gauge<T> newGauge(java.lang.String group, Gauge<T> gauge)
MetricsRegistry
Gauge
newGauge
in interface MetricsRegistry
T
- Type the Gauge will be wrappinggroup
- Group for this Gaugegauge
- Initial value for the Gauge