Class MeterRegistryFactory.Builder
java.lang.Object
io.helidon.integrations.micrometer.MeterRegistryFactory.Builder
- All Implemented Interfaces:
Builder<MeterRegistryFactory.Builder,
,MeterRegistryFactory> Supplier<MeterRegistryFactory>
- Enclosing class:
- MeterRegistryFactory
public static class MeterRegistryFactory.Builder
extends Object
implements Builder<MeterRegistryFactory.Builder,MeterRegistryFactory>
Builder for constructing
MeterRegistryFactory
instances.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Build the instance from this builder.Override default configuration.enrollBuiltInRegistry
(MeterRegistryFactory.BuiltInRegistryType builtInRegistryType) Enrolls a built-in registry type using the default configuration for that type.enrollBuiltInRegistry
(MeterRegistryFactory.BuiltInRegistryType builtInRegistryType, io.micrometer.core.instrument.config.MeterRegistryConfig meterRegistryConfig) Enrolls a built-in registry type to support.enrollRegistry
(io.micrometer.core.instrument.MeterRegistry meterRegistry, Function<ServerRequest, Optional<Handler>> handlerFunction) Records aMetricRegistry
to be managed byMicrometerSupport
, along with the function that returns anOptional
of aHandler
for processing a given request to the Micrometer endpoint.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
build
Description copied from interface:Builder
Build the instance from this builder.- Specified by:
build
in interfaceBuilder<MeterRegistryFactory.Builder,
MeterRegistryFactory> - Returns:
- instance of the built type
-
config
Override default configuration.The config items supported vary from one built-in type to the next. See the documentation for the corresponding
MicrometerRegistryConfig
for details.- Parameters:
config
- configuration instance- Returns:
- updated builder instance
-
enrollBuiltInRegistry
public MeterRegistryFactory.Builder enrollBuiltInRegistry(MeterRegistryFactory.BuiltInRegistryType builtInRegistryType, io.micrometer.core.instrument.config.MeterRegistryConfig meterRegistryConfig) Enrolls a built-in registry type to support.- Parameters:
builtInRegistryType
- built-in meter registry type to supportmeterRegistryConfig
- appropriateMeterRegistryConfig
instance setting up the meter registry- Returns:
- updated builder instance
-
enrollBuiltInRegistry
public MeterRegistryFactory.Builder enrollBuiltInRegistry(MeterRegistryFactory.BuiltInRegistryType builtInRegistryType) Enrolls a built-in registry type using the default configuration for that type.- Parameters:
builtInRegistryType
- built-in meter registry type to support- Returns:
- updated builder instance
-
enrollRegistry
public MeterRegistryFactory.Builder enrollRegistry(io.micrometer.core.instrument.MeterRegistry meterRegistry, Function<ServerRequest, Optional<Handler>> handlerFunction) Records aMetricRegistry
to be managed byMicrometerSupport
, along with the function that returns anOptional
of aHandler
for processing a given request to the Micrometer endpoint.- Parameters:
meterRegistry
- the registry to enrollhandlerFunction
- returnsOptional<Handler>
; if present, capable of responding to the specified request- Returns:
- updated builder instance
-