Class MetricReader
java.lang.Object
io.opencensus.exporter.metrics.util.MetricReader
Helper class to read all available
Metric
s from a MetricProducerManager
and
exports them to a MetricExporter
.- Since:
- 0.19
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
MetricReader
(MetricProducerManager metricProducerManager, String spanName) -
Method Summary
Modifier and TypeMethodDescriptionstatic MetricReader
create
(MetricReader.Options options) Creates a newMetricReader
.private static String
void
readAndExport
(MetricExporter metricExporter) Reads the metrics from theMetricProducerManager
and exports them to themetricExporter
.
-
Field Details
-
tracer
-
logger
-
probabilitySampler
-
DEFAULT_SPAN_NAME
- See Also:
-
metricProducerManager
-
spanName
-
-
Constructor Details
-
MetricReader
-
-
Method Details
-
create
Creates a newMetricReader
.- Parameters:
options
- the options forMetricReader
.- Returns:
- a new
MetricReader
. - Since:
- 0.19
-
readAndExport
Reads the metrics from theMetricProducerManager
and exports them to themetricExporter
.- Parameters:
metricExporter
- the exporter called to export the metrics read.- Since:
- 0.19
-
exceptionMessage
-