Class MicrometerMetricsFactoryProvider
java.lang.Object
io.helidon.metrics.providers.micrometer.MicrometerMetricsFactoryProvider
- All Implemented Interfaces:
MetricsFactoryProvider
Provides the Micrometer meter registry to use as a delegate for the implementation of the Helidon metrics API.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Closes all metrics factories created by this provider.create
(Config rootConfig, MetricsConfig metricsConfig, Collection<MetersProvider> metersProviders) Creates a newMetricsFactory
from which the caller can obtainMeterRegistry
andMeter.Builder
instances.
-
Constructor Details
-
MicrometerMetricsFactoryProvider
public MicrometerMetricsFactoryProvider()Creates a newMetricsFactory
based on Micrometer. Public for service loading.
-
-
Method Details
-
create
public MetricsFactory create(Config rootConfig, MetricsConfig metricsConfig, Collection<MetersProvider> metersProviders) Description copied from interface:MetricsFactoryProvider
Creates a newMetricsFactory
from which the caller can obtainMeterRegistry
andMeter.Builder
instances.The
metricsConfig
parameter will have been derived from therootConfig
. In many cases the new factory will only need to know the metrics configuration so that object is provided as a convenience. The root config node allows the factory to use information from elsewhere in the config tree if needed.- Specified by:
create
in interfaceMetricsFactoryProvider
- Parameters:
rootConfig
- rootConfig
nodemetricsConfig
-MetricsConfig
settingsmetersProviders
- group ofMetersProvider
which can furnishMeter.Builder
instances- Returns:
- new metrics factory
-
close
public void close()Description copied from interface:MetricsFactoryProvider
Closes all metrics factories created by this provider.Applications do not normally need to invoke this method.
- Specified by:
close
in interfaceMetricsFactoryProvider
-