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 Details

    • Builder

      public Builder()
  • Method Details

    • build

      public MeterRegistryFactory build()
      Description copied from interface: Builder
      Build the instance from this builder.
      Specified by:
      build in interface Builder<MeterRegistryFactory.Builder,MeterRegistryFactory>
      Returns:
      instance of the built type
    • config

      public MeterRegistryFactory.Builder config(Config 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 support
      meterRegistryConfig - appropriate MeterRegistryConfig 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 a MetricRegistry to be managed by MicrometerSupport, along with the function that returns an Optional of a Handler for processing a given request to the Micrometer endpoint.
      Parameters:
      meterRegistry - the registry to enroll
      handlerFunction - returns Optional<Handler>; if present, capable of responding to the specified request
      Returns:
      updated builder instance