Class ObserveFeature.Builder

java.lang.Object
io.helidon.nima.observe.ObserveFeature.Builder
All Implemented Interfaces:
Builder<ObserveFeature.Builder,ObserveFeature>, Supplier<ObserveFeature>
Enclosing class:
ObserveFeature

public static class ObserveFeature.Builder extends Object implements Builder<ObserveFeature.Builder,ObserveFeature>
Fluent API builder for ObserveFeature.
  • Method Details

    • build

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

      public ObserveFeature.Builder useSystemServices(boolean useServices)
      Whether to use services discovered by ServiceLoader.
      Parameters:
      useServices - set to false to disable discovery
      Returns:
      updated builder
    • addProvider

      public ObserveFeature.Builder addProvider(ObserveProvider provider)
      Add a provider.
      Parameters:
      provider - provider to use
      Returns:
      updated builder
    • config

      public ObserveFeature.Builder config(Config config)
      Update this builder from configuration.
      Parameters:
      config - config on the node of observe support
      Returns:
      updated builder
    • corsSupport

      public ObserveFeature.Builder corsSupport(CorsSupport cors)
      Cors support inherited by each observe provider, unless explicitly configured.
      Parameters:
      cors - cors support to use
      Returns:
      updated builder
    • enabled

      public ObserveFeature.Builder enabled(boolean enabled)
      Whether the observe support is enabled.
      Parameters:
      enabled - set to false to disable observe feature
      Returns:
      updated builder
    • endpoint

      public ObserveFeature.Builder endpoint(String endpoint)
      Root endpoint to use for observe providers. By default all observe endpoint are under this root endpoint.

      Example:
      If root endpoint is /observe (the default), and default health endpoint is health (relative), health endpoint would be /observe/health.

      Parameters:
      endpoint - endpoint to use
      Returns:
      updated builder