Class JsonMeterRegistryFormatterProvider
java.lang.Object
io.helidon.webserver.observe.metrics.JsonMeterRegistryFormatterProvider
- All Implemented Interfaces:
MeterRegistryFormatterProvider
public class JsonMeterRegistryFormatterProvider
extends Object
implements MeterRegistryFormatterProvider
JSON formatter provider.
-
Constructor Summary
ConstructorDescriptionCreates a new instance for service loading. -
Method Summary
Modifier and TypeMethodDescriptionformatter
(MediaType mediaType, MetricsConfig metricsConfig, MeterRegistry meterRegistry, Optional<String> scopeTagName, Iterable<String> scopeSelection, Iterable<String> nameSelection) Returns, if possible, aMeterRegistryFormatter
capable of preparing output according to the specifiedMediaType
.
-
Constructor Details
-
JsonMeterRegistryFormatterProvider
public JsonMeterRegistryFormatterProvider()Creates a new instance for service loading.
-
-
Method Details
-
formatter
public Optional<MeterRegistryFormatter> formatter(MediaType mediaType, MetricsConfig metricsConfig, MeterRegistry meterRegistry, Optional<String> scopeTagName, Iterable<String> scopeSelection, Iterable<String> nameSelection) Description copied from interface:MeterRegistryFormatterProvider
Returns, if possible, aMeterRegistryFormatter
capable of preparing output according to the specifiedMediaType
.- Specified by:
formatter
in interfaceMeterRegistryFormatterProvider
- Parameters:
mediaType
- media type of the desired outputmetricsConfig
-MetricsConfig
to influence the formattingmeterRegistry
-MeterRegistry
from which to gather datascopeTagName
- tag name used to record scopescopeSelection
- scope names to format; empty means no scope-based restrictionnameSelection
- meter names to format; empty means no name-based restriction- Returns:
- compatible formatter; empty if none
-