Package io.helidon.telemetry.otelconfig
Class OpenTelemetryLoggingConfig.BuilderBase<BUILDER extends OpenTelemetryLoggingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryLoggingConfig>
java.lang.Object
io.helidon.telemetry.otelconfig.OpenTelemetryLoggingConfig.BuilderBase<BUILDER,PROTOTYPE>
- Type Parameters:
BUILDER- type of the builder extending this abstract builderPROTOTYPE- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER,,PROTOTYPE> ConfigBuilderSupport.ConfiguredBuilder<BUILDER,,PROTOTYPE> ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>
- Direct Known Subclasses:
OpenTelemetryLoggingConfig.Builder
- Enclosing interface:
OpenTelemetryLoggingConfig
public abstract static class OpenTelemetryLoggingConfig.BuilderBase<BUILDER extends OpenTelemetryLoggingConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OpenTelemetryLoggingConfig>
extends Object
implements ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>
Fluent API builder base for
OpenTelemetryLoggingConfig.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classGenerated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddProcessor(io.opentelemetry.sdk.logs.LogRecordProcessor processor) Pre-constructed (non-configured) logging processors.addProcessors(List<? extends io.opentelemetry.sdk.logs.LogRecordProcessor> processors) Pre-constructed (non-configured) logging processors.Optional<io.opentelemetry.api.common.AttributesBuilder> Name/value pairs passed to OpenTelemetry.attributes(io.opentelemetry.api.common.AttributesBuilder attributes) Name/value pairs passed to OpenTelemetry.Clear existing value of attributes.Clear existing value of enabled.Clear existing value of logLimits.Clear existing value of minimumSeverity.Clear all processors.Clear existing value of traceBased.config()Configuration used to configure this instance.Deprecated.Update builder from configuration (node of this type).enabled()Whether the OpenTelemetry logger should be enabled.enabled(boolean enabled) Whether the OpenTelemetry logger should be enabled.from(OpenTelemetryLoggingConfig prototype) Update this builder from an existing prototype instance.from(OpenTelemetryLoggingConfig.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.Optional<io.opentelemetry.sdk.logs.LogLimits> Log limits to apply to log transmission.logLimits(io.opentelemetry.sdk.logs.LogLimits logLimits) Log limits to apply to log transmission.Log limits to apply to log transmission.Log limits to apply to log transmission.Optional<io.opentelemetry.api.logs.Severity> Minimum severity level of log records to process.minimumSeverity(io.opentelemetry.api.logs.Severity minimumSeverity) Minimum severity level of log records to process.protected voidHandles providers and decorators.List<io.opentelemetry.sdk.logs.LogRecordProcessor> Pre-constructed (non-configured) logging processors.processors(List<? extends io.opentelemetry.sdk.logs.LogRecordProcessor> processors) Pre-constructed (non-configured) logging processors.toString()Whether to include only log records from traces which are sampled.traceBased(boolean traceBased) Whether to include only log records from traces which are sampled.protected voidValidates required properties.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface io.helidon.builder.api.Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
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
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.Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
configin interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends OpenTelemetryLoggingConfig.BuilderBase<BUILDER,PROTOTYPE>, PROTOTYPE extends OpenTelemetryLoggingConfig> - Parameters:
config- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
config
Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
configin interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends OpenTelemetryLoggingConfig.BuilderBase<BUILDER,PROTOTYPE>, PROTOTYPE extends OpenTelemetryLoggingConfig> - Parameters:
config- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
clearEnabled
Clear existing value of enabled.- Returns:
- updated builder instance
- See Also:
-
enabled
Whether the OpenTelemetry logger should be enabled. (Passed to OpenTelemetry.)- Parameters:
enabled- true if the OpenTelemetry logger should be enabled, false otherwise- Returns:
- updated builder instance
- See Also:
-
clearMinimumSeverity
Clear existing value of minimumSeverity.- Returns:
- updated builder instance
- See Also:
-
minimumSeverity
Minimum severity level of log records to process.- Parameters:
minimumSeverity- minimum severity level- Returns:
- updated builder instance
- See Also:
-
clearTraceBased
Clear existing value of traceBased.- Returns:
- updated builder instance
- See Also:
-
traceBased
Whether to include only log records from traces which are sampled. Defaults to the OpenTelemetry default.- Parameters:
traceBased- whether to restrict exported log records to only those from sampled traces- Returns:
- updated builder instance
- See Also:
-
clearLogLimits
Clear existing value of logLimits.- Returns:
- updated builder instance
- See Also:
-
logLimits
Log limits to apply to log transmission.- Parameters:
logLimits- log limits- Returns:
- updated builder instance
- See Also:
-
logLimits
Log limits to apply to log transmission.- Parameters:
consumer- consumer of builder of log limits- Returns:
- updated builder instance
- See Also:
-
logLimits
Log limits to apply to log transmission.- Parameters:
supplier- supplier of log limits- Returns:
- updated builder instance
- See Also:
-
clearProcessors
Clear all processors.- Returns:
- updated builder instance
- See Also:
-
processors
Pre-constructed (non-configured) logging processors.- Parameters:
processors- logging processors- Returns:
- updated builder instance
- See Also:
-
addProcessors
public BUILDER addProcessors(List<? extends io.opentelemetry.sdk.logs.LogRecordProcessor> processors) Pre-constructed (non-configured) logging processors.- Parameters:
processors- logging processors- Returns:
- updated builder instance
- See Also:
-
addProcessor
Pre-constructed (non-configured) logging processors.- Parameters:
processor- add single logging processors- Returns:
- updated builder instance
- See Also:
-
clearAttributes
Clear existing value of attributes.- Returns:
- updated builder instance
- See Also:
-
attributes
Name/value pairs passed to OpenTelemetry.- Parameters:
attributes- typed attribute settings- Returns:
- updated builder instance
- See Also:
-
enabled
Whether the OpenTelemetry logger should be enabled. (Passed to OpenTelemetry.)- Returns:
- true if the OpenTelemetry logger should be enabled, false otherwise
-
minimumSeverity
Minimum severity level of log records to process.- Returns:
- minimum severity level
-
traceBased
Whether to include only log records from traces which are sampled. Defaults to the OpenTelemetry default.- Returns:
- whether to restrict exported log records to only those from sampled traces
-
logLimits
Log limits to apply to log transmission.- Returns:
- log limits
-
processors
Pre-constructed (non-configured) logging processors.- Returns:
- logging processors
-
attributes
Name/value pairs passed to OpenTelemetry.- Returns:
- typed attribute settings
-
toString
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties. -
config
Configuration used to configure this instance.- Returns:
- config instance
-
config(io.helidon.config.Config)