Class SpringWebfluxTelemetryClientBuilder
java.lang.Object
io.opentelemetry.instrumentation.spring.webflux.v5_3.internal.SpringWebfluxTelemetryClientBuilder
This class is internal and is hence not for public use. Its APIs are unstable and can change at
any time.
-
Constructor Summary
ConstructorsConstructorDescriptionSpringWebfluxTelemetryClientBuilder(io.opentelemetry.api.OpenTelemetry openTelemetry) -
Method Summary
Modifier and TypeMethodDescriptionaddClientAttributesExtractor(io.opentelemetry.instrumentation.api.instrumenter.AttributesExtractor<org.springframework.web.reactive.function.client.ClientRequest, org.springframework.web.reactive.function.client.ClientResponse> attributesExtractor) Adds an additionalAttributesExtractorto invoke to set attributes to instrumented items for WebClient.io.opentelemetry.instrumentation.api.instrumenter.Instrumenter<org.springframework.web.reactive.function.client.ClientRequest,org.springframework.web.reactive.function.client.ClientResponse> build()Returns a newSpringWebfluxTelemetrywith the settings of thisSpringWebfluxTelemetryClientBuilder.setCapturedClientRequestHeaders(List<String> requestHeaders) Configures the HTTP WebClient request headers that will be captured as span attributes.setCapturedClientResponseHeaders(List<String> responseHeaders) Configures the HTTP WebClient response headers that will be captured as span attributes.setCaptureExperimentalSpanAttributes(boolean captureExperimentalSpanAttributes) Sets whether experimental attributes should be set to spans.
-
Constructor Details
-
SpringWebfluxTelemetryClientBuilder
public SpringWebfluxTelemetryClientBuilder(io.opentelemetry.api.OpenTelemetry openTelemetry)
-
-
Method Details
-
addClientAttributesExtractor
@CanIgnoreReturnValue public SpringWebfluxTelemetryClientBuilder addClientAttributesExtractor(io.opentelemetry.instrumentation.api.instrumenter.AttributesExtractor<org.springframework.web.reactive.function.client.ClientRequest, org.springframework.web.reactive.function.client.ClientResponse> attributesExtractor) Adds an additionalAttributesExtractorto invoke to set attributes to instrumented items for WebClient. -
setCapturedClientRequestHeaders
@CanIgnoreReturnValue public SpringWebfluxTelemetryClientBuilder setCapturedClientRequestHeaders(List<String> requestHeaders) Configures the HTTP WebClient request headers that will be captured as span attributes.- Parameters:
requestHeaders- A list of HTTP header names.
-
setCapturedClientResponseHeaders
@CanIgnoreReturnValue public SpringWebfluxTelemetryClientBuilder setCapturedClientResponseHeaders(List<String> responseHeaders) Configures the HTTP WebClient response headers that will be captured as span attributes.- Parameters:
responseHeaders- A list of HTTP header names.
-
setCaptureExperimentalSpanAttributes
@CanIgnoreReturnValue public SpringWebfluxTelemetryClientBuilder setCaptureExperimentalSpanAttributes(boolean captureExperimentalSpanAttributes) Sets whether experimental attributes should be set to spans. These attributes may be changed or removed in the future, so only enable this if you know you do not require attributes filled by this instrumentation to be stable across versions. -
build
public io.opentelemetry.instrumentation.api.instrumenter.Instrumenter<org.springframework.web.reactive.function.client.ClientRequest,org.springframework.web.reactive.function.client.ClientResponse> build()Returns a newSpringWebfluxTelemetrywith the settings of thisSpringWebfluxTelemetryClientBuilder.
-