Class OpenTelemetryTracingConfig.BuilderBase<BUILDER extends OpenTelemetryTracingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryTracingConfig>

java.lang.Object
io.helidon.telemetry.otelconfig.OpenTelemetryTracingConfig.BuilderBase<BUILDER,PROTOTYPE>
Type Parameters:
BUILDER - type of the builder extending this abstract builder
PROTOTYPE - type of the prototype interface that would be built by Prototype.Builder.buildPrototype()
All Implemented Interfaces:
Prototype.Builder<BUILDER,PROTOTYPE>, ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>, ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>
Direct Known Subclasses:
OpenTelemetryTracingConfig.Builder
Enclosing interface:
OpenTelemetryTracingConfig

public abstract static class OpenTelemetryTracingConfig.BuilderBase<BUILDER extends OpenTelemetryTracingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryTracingConfig> extends Object implements ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>
Fluent API builder base for OpenTelemetryTracingConfig.
  • Constructor Details

    • BuilderBase

      protected BuilderBase()
      Protected to support extensibility.
  • Method Details

    • from

      public BUILDER from(OpenTelemetryTracingConfig prototype)
      Update this builder from an existing prototype instance. This method disables automatic service discovery.
      Parameters:
      prototype - existing prototype to update this builder from
      Returns:
      updated builder instance
    • from

      public BUILDER from(OpenTelemetryTracingConfig.BuilderBase<?,?> builder)
      Update this builder from an existing prototype builder instance.
      Parameters:
      builder - existing builder prototype to update this builder from
      Returns:
      updated builder instance
    • config

      @Deprecated public BUILDER config(Config config)
      Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.
      Specified by:
      config in interface ConfigBuilderSupport.ConfiguredBuilder<BUILDER extends OpenTelemetryTracingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryTracingConfig>
      Parameters:
      config - configuration instance used to obtain values to update this builder
      Returns:
      updated builder instance
    • config

      public BUILDER config(Config config)
      Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.
      Specified by:
      config in interface ConfigBuilderSupport.ConfiguredBuilder<BUILDER extends OpenTelemetryTracingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryTracingConfig>
      Parameters:
      config - configuration instance used to obtain values to update this builder
      Returns:
      updated builder instance
    • clearSampler

      public BUILDER clearSampler()
      Clear existing value of this property.
      Returns:
      updated builder instance
      See Also:
    • sampler

      public BUILDER sampler(io.opentelemetry.sdk.trace.samplers.Sampler sampler)
      Tracing sampler.
      Parameters:
      sampler - tracing sampler
      Returns:
      updated builder instance
      See Also:
    • clearSpanLimits

      public BUILDER clearSpanLimits()
      Clear existing value of this property.
      Returns:
      updated builder instance
      See Also:
    • spanLimits

      public BUILDER spanLimits(io.opentelemetry.sdk.trace.SpanLimits spanLimits)
      Tracing span limits.
      Parameters:
      spanLimits - tracing span limits
      Returns:
      updated builder instance
      See Also:
    • processors

      public BUILDER processors(List<? extends io.opentelemetry.sdk.trace.SpanProcessor> processors)
      Constructed span processors.
      Parameters:
      processors - span processors
      Returns:
      updated builder instance
      See Also:
    • addProcessors

      public BUILDER addProcessors(List<? extends io.opentelemetry.sdk.trace.SpanProcessor> processors)
      Constructed span processors.
      Parameters:
      processors - span processors
      Returns:
      updated builder instance
      See Also:
    • addProcessor

      public BUILDER addProcessor(io.opentelemetry.sdk.trace.SpanProcessor processor)
      Constructed span processors.
      Parameters:
      processor - span processors
      Returns:
      updated builder instance
      See Also:
    • stringAttributes

      public BUILDER stringAttributes(Map<String,String> stringAttributes)
      String attributes. This method replaces all values with the new ones.
      Parameters:
      stringAttributes - string attributes
      Returns:
      updated builder instance
      See Also:
    • addStringAttributes

      public BUILDER addStringAttributes(Map<String,String> stringAttributes)
      String attributes. This method keeps existing values, then puts all new values into the map.
      Parameters:
      stringAttributes - string attributes
      Returns:
      updated builder instance
      See Also:
    • putStringAttribute

      public BUILDER putStringAttribute(String key, String stringAttribute)
      String attributes. This method adds a new value to the map, or replaces it if the key already exists.
      Parameters:
      key - key to add or replace
      stringAttribute - new value for the key
      Returns:
      updated builder instance
      See Also:
    • booleanAttributes

      public BUILDER booleanAttributes(Map<String,Boolean> booleanAttributes)
      Boolean attributes. This method replaces all values with the new ones.
      Parameters:
      booleanAttributes - boolean attributes
      Returns:
      updated builder instance
      See Also:
    • addBooleanAttributes

      public BUILDER addBooleanAttributes(Map<String,Boolean> booleanAttributes)
      Boolean attributes. This method keeps existing values, then puts all new values into the map.
      Parameters:
      booleanAttributes - boolean attributes
      Returns:
      updated builder instance
      See Also:
    • putBooleanAttribute

      public BUILDER putBooleanAttribute(String key, Boolean booleanAttribute)
      Boolean attributes. This method adds a new value to the map, or replaces it if the key already exists.
      Parameters:
      key - key to add or replace
      booleanAttribute - new value for the key
      Returns:
      updated builder instance
      See Also:
    • longAttributes

      public BUILDER longAttributes(Map<String,Long> longAttributes)
      Long attributes. This method replaces all values with the new ones.
      Parameters:
      longAttributes - long attributes
      Returns:
      updated builder instance
      See Also:
    • addLongAttributes

      public BUILDER addLongAttributes(Map<String,Long> longAttributes)
      Long attributes. This method keeps existing values, then puts all new values into the map.
      Parameters:
      longAttributes - long attributes
      Returns:
      updated builder instance
      See Also:
    • putLongAttribute

      public BUILDER putLongAttribute(String key, Long longAttribute)
      Long attributes. This method adds a new value to the map, or replaces it if the key already exists.
      Parameters:
      key - key to add or replace
      longAttribute - new value for the key
      Returns:
      updated builder instance
      See Also:
    • doubleAttributes

      public BUILDER doubleAttributes(Map<String,Double> doubleAttributes)
      Double attributes. This method replaces all values with the new ones.
      Parameters:
      doubleAttributes - double attributes
      Returns:
      updated builder instance
      See Also:
    • addDoubleAttributes

      public BUILDER addDoubleAttributes(Map<String,Double> doubleAttributes)
      Double attributes. This method keeps existing values, then puts all new values into the map.
      Parameters:
      doubleAttributes - double attributes
      Returns:
      updated builder instance
      See Also:
    • putDoubleAttribute

      public BUILDER putDoubleAttribute(String key, Double doubleAttribute)
      Double attributes. This method adds a new value to the map, or replaces it if the key already exists.
      Parameters:
      key - key to add or replace
      doubleAttribute - new value for the key
      Returns:
      updated builder instance
      See Also:
    • sampler

      public Optional<io.opentelemetry.sdk.trace.samplers.Sampler> sampler()
      Tracing sampler.
      Returns:
      the sampler
    • spanLimits

      public Optional<io.opentelemetry.sdk.trace.SpanLimits> spanLimits()
      Tracing span limits.
      Returns:
      the span limits
    • processors

      public List<io.opentelemetry.sdk.trace.SpanProcessor> processors()
      Constructed span processors.
      Returns:
      the processors
    • stringAttributes

      public Map<String,String> stringAttributes()
      String attributes.
      Returns:
      the string attributes
    • booleanAttributes

      public Map<String,Boolean> booleanAttributes()
      Boolean attributes.
      Returns:
      the boolean attributes
    • longAttributes

      public Map<String,Long> longAttributes()
      Long attributes.
      Returns:
      the long attributes
    • doubleAttributes

      public Map<String,Double> doubleAttributes()
      Double attributes.
      Returns:
      the double attributes
    • config

      public Optional<Config> config()
      If this instance was configured, this would be the config instance used.
      Returns:
      config node used to configure this builder, or empty if not configured
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • preBuildPrototype

      protected void preBuildPrototype()
      Handles providers and decorators.
    • validatePrototype

      protected void validatePrototype()
      Validates required properties.