Class NoopMetricsSystem
java.lang.Object
org.apache.calcite.avatica.metrics.noop.NoopMetricsSystem
- All Implemented Interfaces:
MetricsSystem
MetricsSystem implementation which does nothing. Returns Metric implementations
which also does nothing (avoiding null instances).-
Method Summary
Modifier and TypeMethodDescriptiongetCounter(String name) Get or construct aCounterused to track a mutable number.getHistogram(String name) Get or construct aHistogramused to measure a distribution of values.static NoopMetricsSystemGet or construct aTimerused to measure durations and report rates.<T> voidRegister aGauge.
-
Method Details
-
getInstance
- Returns:
- A
NoopMetricsSysteminstance.
-
getTimer
Description copied from interface:MetricsSystemGet or construct aTimerused to measure durations and report rates.- Specified by:
getTimerin interfaceMetricsSystem- Parameters:
name- The name of the Timer.- Returns:
- An instance of
Timer.
-
getHistogram
Description copied from interface:MetricsSystemGet or construct aHistogramused to measure a distribution of values.- Specified by:
getHistogramin interfaceMetricsSystem- Parameters:
name- The name of the Histogram.- Returns:
- An instance of
Histogram.
-
getMeter
Description copied from interface:MetricsSystemGet or construct aMeterused to measure durations and report distributions (a combination of aTimerand aHistogram.- Specified by:
getMeterin interfaceMetricsSystem- Parameters:
name- The name of the Meter.- Returns:
- An instance of
Meter.
-
getCounter
Description copied from interface:MetricsSystemGet or construct aCounterused to track a mutable number.- Specified by:
getCounterin interfaceMetricsSystem- Parameters:
name- The name of the Counter- Returns:
- An instance of
Counter.
-
register
Description copied from interface:MetricsSystemRegister aGauge. The Gauge will be invoked at a period defined by the implementation ofMetricsSystem.- Specified by:
registerin interfaceMetricsSystem- Type Parameters:
T- The type of the Gauge.- Parameters:
name- The name of the Gauge.gauge- A callback to compute the current value.
-