// Do not edit directly!
// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
[id="extensions-opentracing"]
= OpenTracing
:page-aliases: extensions/opentracing.adoc
:linkattrs:
:cq-artifact-id: camel-quarkus-opentracing
:cq-native-supported: true
:cq-status: Stable
:cq-status-deprecation: Stable Deprecated
:cq-description: Distributed tracing using OpenTracing
:cq-deprecated: true
:cq-jvm-since: 0.3.0
:cq-native-since: 0.3.0

ifeval::[{doc-show-badges} == true]
[.badges]
[.badge-key]##JVM since##[.badge-supported]##0.3.0## [.badge-key]##Native since##[.badge-supported]##0.3.0## [.badge-key]##⚠️##[.badge-unsupported]##Deprecated##
endif::[]

Distributed tracing using OpenTracing

[id="extensions-opentracing-whats-inside"]
== What's inside

* xref:{cq-camel-components}:others:opentracing.adoc[OpenTracing]

Please refer to the above link for usage and configuration details.

[id="extensions-opentracing-maven-coordinates"]
== Maven coordinates

https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-opentracing[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]

Or add the coordinates to your existing project:

[source,xml]
----
<dependency>
    <groupId>org.apache.camel.quarkus</groupId>
    <artifactId>camel-quarkus-opentracing</artifactId>
</dependency>
----
ifeval::[{doc-show-user-guide-link} == true]
Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
endif::[]

[id="extensions-opentracing-usage"]
== Usage
The extension automatically creates a Camel `OpenTracingTracer` and binds it to the Camel registry.

In order to send the captured traces to a tracing system, you need to configure some properties within `application.properties` like those below.

[source,properties]
----
quarkus.jaeger.service-name=my-service
quarkus.jaeger.sampler-type=const
quarkus.jaeger.sampler-param=1
quarkus.jaeger.endpoint=http://localhost:14268/api/traces
----

Refer to the https://quarkus.io/guides/opentracing-guide#configuration-reference[Quarkus OpenTracing guide] for a full list of configuration options.

Route endpoints can be excluded from tracing by configuring a property named `quarkus.camel.opentracing.exclude-patterns` in `application.properties`. For example:

[source,properties]
----
# Exclude all direct & netty-http endpoints from tracing
quarkus.camel.opentracing.exclude-patterns=direct:*,netty-http:*
----


[id="extensions-opentracing-additional-camel-quarkus-configuration"]
== Additional Camel Quarkus configuration

[width="100%",cols="80,5,15",options="header"]
|===
| Configuration property | Type | Default


|icon:lock[title=Fixed at build time] [[quarkus.camel.opentracing.encoding]]`link:#quarkus.camel.opentracing.encoding[quarkus.camel.opentracing.encoding]`

Sets whether header names need to be encoded. Can be useful in situations where OpenTracing propagators potentially set header name values in formats that are not compatible with the target system. E.g for JMS where the specification mandates header names are valid Java identifiers.
| `boolean`
| `false`

|icon:lock[title=Fixed at build time] [[quarkus.camel.opentracing.exclude-patterns]]`link:#quarkus.camel.opentracing.exclude-patterns[quarkus.camel.opentracing.exclude-patterns]`

Sets whether to disable tracing for endpoint URIs that match the given patterns
| `string`
| 
|===

[.configuration-legend]
{doc-link-icon-lock}[title=Fixed at build time] Configuration property fixed at build time. All other configuration properties are overridable at runtime.

