Class JaegerTracerBuilder
java.lang.Object
io.helidon.tracing.providers.jaeger.JaegerTracerBuilder
- All Implemented Interfaces:
Builder<JaegerTracerBuilder,,Tracer> TracerBuilder<JaegerTracerBuilder>,Supplier<Tracer>
@Deprecated(since="4.4.0",
forRemoval=true)
public class JaegerTracerBuilder
extends Object
implements TracerBuilder<JaegerTracerBuilder>
Deprecated, for removal: This API element is subject to removal in a future version.
Use another tracing provider, such as OpenTelemetry.
The JaegerTracerBuilder is a convenience builder for
Tracer to use with Jaeger.
Unless You want to explicitly depend on Jaeger in Your code, please
use TracerBuilder.create(String) or
TracerBuilder.create(io.helidon.common.config.Config) that is abstracted.
The Jaeger tracer uses environment variables and system properties to override the defaults.
Except for protocol and service these are honored, unless overridden in configuration
or through the builder methods.
See Jaeger documentation
for details.
The following table lists jaeger specific defaults and configuration options.
| option | default | description |
|---|---|---|
service |
Service name | |
protocol |
http |
The protocol to use. By default http is used. |
host |
127.0.0.1 |
Host to use |
port |
14250 | Port to be used |
path |
Path to be used. | |
exporter-timeout |
10 seconds | Timeout of exporter |
private-key-pem |
Client private key in PEM format | |
client-cert-pem |
Client certificate in PEM format | |
trusted-cert-pem |
Trusted certificates in PEM format | |
sampler-type |
const with param set to 1 |
Sampler type const (0 to disable, 1 to always enabled),
ratio (sample param contains the ratio as a double) |
sampler-param |
sampler type default | Numeric parameter specifying details for the sampler type. |
tags |
see TracerBuilder |
|
boolean-tags |
see TracerBuilder |
|
int-tags |
see TracerBuilder |
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumDeprecated, for removal: This API element is subject to removal in a future version.Supported Jaeger trace context propagation formats.static enumDeprecated, for removal: This API element is subject to removal in a future version.Sampler type definition.static enumDeprecated, for removal: This API element is subject to removal in a future version.Span Processor type. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedDeprecated, for removal: This API element is subject to removal in a future version.Default constructor, does not modify any state. -
Method Summary
Modifier and TypeMethodDescriptionaddPropagation(JaegerTracerBuilder.PropagationFormat propagationFormat) Deprecated, for removal: This API element is subject to removal in a future version.Add propagation format to use.addSpanExporter(io.opentelemetry.sdk.trace.export.SpanExporter spanExporter) Deprecated, for removal: This API element is subject to removal in a future version.Add a span exporter.addTracerTag(String key, boolean value) Deprecated, for removal: This API element is subject to removal in a future version.Tracer level tags that get added to all reported spans.addTracerTag(String key, Number value) Deprecated, for removal: This API element is subject to removal in a future version.Tracer level tags that get added to all reported spans.addTracerTag(String key, String value) Deprecated, for removal: This API element is subject to removal in a future version.Tracer level tags that get added to all reported spans.build()Deprecated, for removal: This API element is subject to removal in a future version.Builds theTracerfor Jaeger based on the configured parameters.clientCertificate(Resource resource) Deprecated, for removal: This API element is subject to removal in a future version.Certificate of client in PEM format.collectorHost(String host) Deprecated, for removal: This API element is subject to removal in a future version.Host to use to connect to tracing collector.collectorPath(String path) Deprecated, for removal: This API element is subject to removal in a future version.Path on the collector host to use when sending data to tracing collector.collectorPort(int port) Deprecated, for removal: This API element is subject to removal in a future version.Port to use to connect to tracing collector.collectorProtocol(String protocol) Deprecated, for removal: This API element is subject to removal in a future version.Protocol to use (such ashttporhttps) to connect to tracing collector.Deprecated, for removal: This API element is subject to removal in a future version.Load configuration of tracer from configuration of the application.static JaegerTracerBuilderDeprecated, for removal: This API element is subject to removal in a future version.usecreate(io.helidon.config.Config)insteadstatic JaegerTracerBuilderDeprecated, for removal: This API element is subject to removal in a future version.Create a new builder based on values in configuration.enabled(boolean enabled) Deprecated, for removal: This API element is subject to removal in a future version.When enabled, tracing will be sent.exporterTimeout(Duration exporterTimeout) Deprecated, for removal: This API element is subject to removal in a future version.Timeout of exporter requests.static JaegerTracerBuilderforService(String serviceName) Deprecated, for removal: This API element is subject to removal in a future version.Get a JaegerTracerbuilder for processing tracing data of a service with a given name.maxExportBatchSize(int maxExportBatchSize) Deprecated, for removal: This API element is subject to removal in a future version.Maximum Export Batch Size of exporter requests.maxQueueSize(int maxQueueSize) Deprecated, for removal: This API element is subject to removal in a future version.Maximum Queue Size of exporter requests.privateKey(Resource resource) Deprecated, for removal: This API element is subject to removal in a future version.Private key in PEM format.registerGlobal(boolean global) Deprecated, for removal: This API element is subject to removal in a future version.When enabled, the created instance is also registered as a global tracer.samplerParam(Number samplerParam) Deprecated, for removal: This API element is subject to removal in a future version.The sampler parameter (number).samplerType(JaegerTracerBuilder.SamplerType samplerType) Deprecated, for removal: This API element is subject to removal in a future version.Sampler type.scheduleDelay(Duration scheduleDelay) Deprecated, for removal: This API element is subject to removal in a future version.Schedule Delay of exporter requests.serviceName(String name) Deprecated, for removal: This API element is subject to removal in a future version.Service name of the traced service.spanProcessorType(JaegerTracerBuilder.SpanProcessorType spanProcessorType) Deprecated, for removal: This API element is subject to removal in a future version.Span Processor type used.trustedCertificates(Resource resource) Deprecated, for removal: This API element is subject to removal in a future version.Trusted certificates in PEM format.<B> BDeprecated, for removal: This API element is subject to removal in a future version.Access the underlying builder by specific type.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.helidon.tracing.TracerBuilder
collectorUri, config
-
Constructor Details
-
JaegerTracerBuilder
protected JaegerTracerBuilder()Deprecated, for removal: This API element is subject to removal in a future version.Default constructor, does not modify any state.
-
-
Method Details
-
forService
Deprecated, for removal: This API element is subject to removal in a future version.Get a JaegerTracerbuilder for processing tracing data of a service with a given name.- Parameters:
serviceName- name of the service that will be using the tracer.- Returns:
Tracerbuilder for Jaeger.
-
create
Deprecated, for removal: This API element is subject to removal in a future version.usecreate(io.helidon.config.Config)insteadCreate a new builder based on values in configuration. This requires at least a key "service" in the provided config.- Parameters:
config- configuration to load this builder from- Returns:
- a new builder instance.
-
create
Deprecated, for removal: This API element is subject to removal in a future version.Create a new builder based on values in configuration. This requires at least a key "service" in the provided config.- Parameters:
config- configuration to load this builder from- Returns:
- a new builder instance.
- See Also:
-
serviceName
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderService name of the traced service.- Specified by:
serviceNamein interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
name- name of the service using the tracer- Returns:
- updated builder instance
-
collectorProtocol
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderProtocol to use (such ashttporhttps) to connect to tracing collector. Default is defined by each tracing integration.- Specified by:
collectorProtocolin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
protocol- protocol to use- Returns:
- updated builder instance
-
collectorPort
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderPort to use to connect to tracing collector. Default is defined by each tracing integration.- Specified by:
collectorPortin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
port- port to use- Returns:
- updated builder instance
-
collectorPath
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderPath on the collector host to use when sending data to tracing collector. Default is defined by each tracing integration.- Specified by:
collectorPathin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
path- path to use- Returns:
- updated builder instance
-
collectorHost
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderHost to use to connect to tracing collector. Default is defined by each tracing integration.- Specified by:
collectorHostin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
host- host to use- Returns:
- updated builder instance
-
addTracerTag
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderTracer level tags that get added to all reported spans.- Specified by:
addTracerTagin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
key- name of the tagvalue- value of the tag- Returns:
- updated builder instance
-
addTracerTag
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderTracer level tags that get added to all reported spans.- Specified by:
addTracerTagin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
key- name of the tagvalue- numeric value of the tag- Returns:
- updated builder instance
-
addTracerTag
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderTracer level tags that get added to all reported spans.- Specified by:
addTracerTagin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
key- name of the tagvalue- boolean value of the tag- Returns:
- updated builder instance
-
config
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderLoad configuration of tracer from configuration of the application. The configuration keys are specific for each tracer integration and documented in these integration projects.API Note: the default method implementation is provided for backward compatibility and will be removed in the next major version
- Specified by:
configin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
config- configuration node of the tracer configuration- Returns:
- updated builder instance
-
privateKey
Deprecated, for removal: This API element is subject to removal in a future version.Private key in PEM format.- Parameters:
resource- key resource- Returns:
- updated builder
-
clientCertificate
Deprecated, for removal: This API element is subject to removal in a future version.Certificate of client in PEM format.- Parameters:
resource- certificate resource- Returns:
- updated builder
-
trustedCertificates
Deprecated, for removal: This API element is subject to removal in a future version.Trusted certificates in PEM format.- Parameters:
resource- trusted certificates resource- Returns:
- updated builder
-
spanProcessorType
public JaegerTracerBuilder spanProcessorType(JaegerTracerBuilder.SpanProcessorType spanProcessorType) Deprecated, for removal: This API element is subject to removal in a future version.Span Processor type used.- Parameters:
spanProcessorType- to use- Returns:
- updated builder
-
scheduleDelay
Deprecated, for removal: This API element is subject to removal in a future version.Schedule Delay of exporter requests.- Parameters:
scheduleDelay- timeout to use- Returns:
- updated builder
-
maxQueueSize
Deprecated, for removal: This API element is subject to removal in a future version.Maximum Queue Size of exporter requests.- Parameters:
maxQueueSize- to use- Returns:
- updated builder
-
maxExportBatchSize
Deprecated, for removal: This API element is subject to removal in a future version.Maximum Export Batch Size of exporter requests.- Parameters:
maxExportBatchSize- to use- Returns:
- updated builder
-
exporterTimeout
Deprecated, for removal: This API element is subject to removal in a future version.Timeout of exporter requests.- Parameters:
exporterTimeout- timeout to use- Returns:
- updated builder
-
enabled
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderWhen enabled, tracing will be sent. If enabled is false, tracing should use a no-op tracer.- Specified by:
enabledin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
enabled- set tofalseto disable distributed tracing- Returns:
- updated builder instance
-
registerGlobal
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderWhen enabled, the created instance is also registered as a global tracer.- Specified by:
registerGlobalin interfaceTracerBuilder<JaegerTracerBuilder>- Parameters:
global- whether to register this tracer as a global tracer once built- Returns:
- updated builder instance
-
unwrap
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:TracerBuilderAccess the underlying builder by specific type. This is a dangerous operation that will succeed only if the builder contains the expected type. This practically removes abstraction capabilities of this builder.- Specified by:
unwrapin interfaceTracerBuilder<JaegerTracerBuilder>- Type Parameters:
B- type of the builder- Parameters:
builderClass- type to access- Returns:
- instance of the builder
-
samplerParam
Deprecated, for removal: This API element is subject to removal in a future version.The sampler parameter (number).- Parameters:
samplerParam- parameter of the sampler- Returns:
- updated builder instance
-
samplerType
Deprecated, for removal: This API element is subject to removal in a future version.Sampler type.See Sampler types.
- Parameters:
samplerType- type of the sampler- Returns:
- updated builder instance
-
addPropagation
Deprecated, for removal: This API element is subject to removal in a future version.Add propagation format to use.- Parameters:
propagationFormat- propagation value- Returns:
- updated builder instance
-
build
Deprecated, for removal: This API element is subject to removal in a future version.Builds theTracerfor Jaeger based on the configured parameters.- Specified by:
buildin interfaceBuilder<JaegerTracerBuilder,Tracer> - Returns:
- the tracer
-
addSpanExporter
public JaegerTracerBuilder addSpanExporter(io.opentelemetry.sdk.trace.export.SpanExporter spanExporter) Deprecated, for removal: This API element is subject to removal in a future version.Add a span exporter.- Parameters:
spanExporter- span exporter to use- Returns:
- updated builder instance
-