Author: buildbot
Date: Sun Aug 27 16:42:54 2023
New Revision: 1084030
Log:
Production update by buildbot for cxf
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_11-57-14.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-13-51.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-19-25.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-21-35.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-23-31.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-25-58.png
(with props)
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-8-52.png
(with props)
Modified:
websites/production/cxf/content/cache/docs.pageCache
websites/production/cxf/content/docs/using-opentelemetry.html
Modified: websites/production/cxf/content/cache/docs.pageCache
==============================================================================
Binary files - no diff available.
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_11-57-14.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_11-57-14.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-13-51.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-13-51.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-19-25.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-19-25.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-21-35.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-21-35.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-23-31.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-23-31.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-25-58.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-25-58.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-8-52.png
==============================================================================
Binary file - no diff available.
Propchange:
websites/production/cxf/content/docs/using-opentelemetry.data/image-2023-8-27_12-8-52.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Modified: websites/production/cxf/content/docs/using-opentelemetry.html
==============================================================================
--- websites/production/cxf/content/docs/using-opentelemetry.html (original)
+++ websites/production/cxf/content/docs/using-opentelemetry.html Sun Aug 27
16:42:54 2023
@@ -107,12 +107,12 @@ Apache CXF -- Using OpenTelemetry
<td height="100%">
<!-- Content -->
<div class="wiki-content">
-<div id="ConfluenceContent"><h1
id="UsingOpenTelemetry-/*<![CDATA[*/div.rbtoc1692564169026{padding:0px;}div.rbtoc1692564169026ul{margin-left:0px;}div.rbtoc1692564169026li{margin-left:0px;padding-left:0px;}/*]]>*/#UsingOpenTelemetry-Overview#UsingOpenTelemetry-OverviewDistributedTracinginApa"><style
type="text/css">/*<![CDATA[*/
-div.rbtoc1692564169026 {padding: 0px;}
-div.rbtoc1692564169026 ul {margin-left: 0px;}
-div.rbtoc1692564169026 li {margin-left: 0px;padding-left: 0px;}
+<div id="ConfluenceContent"><h1
id="UsingOpenTelemetry-/*<![CDATA[*/div.rbtoc1693154570052{padding:0px;}div.rbtoc1693154570052ul{margin-left:0px;}div.rbtoc1693154570052li{margin-left:0px;padding-left:0px;}/*]]>*/#UsingOpenTelemetry-Overview#UsingOpenTelemetry-OverviewDistributedTracinginApa"><style
type="text/css">/*<![CDATA[*/
+div.rbtoc1693154570052 {padding: 0px;}
+div.rbtoc1693154570052 ul {margin-left: 0px;}
+div.rbtoc1693154570052 li {margin-left: 0px;padding-left: 0px;}
-/*]]>*/</style></h1><div class="toc-macro rbtoc1692564169026">
+/*]]>*/</style></h1><div class="toc-macro rbtoc1693154570052">
<ul class="toc-indentation"><li><a shape="rect"
href="#UsingOpenTelemetry-"></a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Overview">Overview</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-DistributedTracinginApacheCXFusingOpenTelemetry">Distributed
Tracing in Apache CXF using OpenTelemetry</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-ConfiguringClient">Configuring Client</a></li><li><a
shape="rect" href="#UsingOpenTelemetry-ConfiguringServer">Configuring
Server</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-DistributedTracingInAction:UsageScenarios">Distributed
Tracing In Action: Usage Scenarios</a>
<ul class="toc-indentation"><li><a shape="rect"
href="#UsingOpenTelemetry-Example#1:ClientandServerwithdefaultdistributedtracingconfigured">Example
#1: Client and Server with default distributed tracing
configured</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Example#2:ClientandServerwithnestedtrace">Example #2:
Client and Server with nested trace</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Example#3:ClientandServertracewithannotations">Example
#3: Client and Server trace with annotations</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Example#4:ClientandServerwithbinaryannotations(key/value)">Example
#4: Client and Server with binary annotations (key/value)</a></li><li><a
shape="rect"
href="#UsingOpenTelemetry-Example#5:ClientandServerwithparalleltrace(involvingthreadpools)">Example
#5: Client and Server with parallel trace (involving thread
pools)</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Example#6:ClientandServerwithasynchronousJAX-RSservice(se
rver-side)">Example #6: Client and Server with asynchronous JAX-RS service
(server-side)</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Example#7:ClientandServerwithasynchronousinvocation(client-side)">Example
#7: Client and Server with asynchronous invocation (client-side)</a></li></ul>
</li><li><a shape="rect"
href="#UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandJAX-WSsupport">Distributed
Tracing with OpenTelemetry and JAX-WS support</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandOSGi">Distributed
Tracing with OpenTelemetry and OSGi</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-SpringXML-Configuration">Spring
XML-Configuration</a></li><li><a shape="rect"
href="#UsingOpenTelemetry-Usingnon-JAX-RSclients">Using non-JAX-RS
clients</a></li></ul>
@@ -196,7 +196,127 @@ final JAXRSServerFactoryBean factory = R
factory.setProvider(new OpenTelemetryFeature(openTelemetry, tracer));
...
return factory.create();</pre>
-</div></div><p>Once the <strong>span processor(s) </strong>and
<strong>sampler</strong> are properly configured, all generated
<strong>spans</strong> are going to be collected and available for analysis
and/or visualization.</p><h1
id="UsingOpenTelemetry-DistributedTracingInAction:UsageScenarios">Distributed
Tracing In Action: Usage Scenarios</h1><p>In the following subsections we are
going to walk through many different scenarios to illustrate the distributed
tracing in action, starting from the simplest ones and finishing with
asynchronous JAX-RS services. All examples assume that configuration
<strong>has been done</strong> (see please <a shape="rect"
href="https://cwiki.apache.org/confluence/display/CXF20DOC/Using+OpenTelemetry#UsingOpenTelemetry-ConfiguringClient"><span
class="confluence-link">Configuring Client</span></a><span
class="confluence-link"> </span> and <a shape="rect"
href="https://cwiki.apache.org/confluence/display/CXF20DOC/Using+OpenTelemetry#UsingOpenTeleme
try-ConfiguringServer"><span class="confluence-link">Configuring
Server</span></a> sections above).</p><h2
id="UsingOpenTelemetry-Example#1:ClientandServerwithdefaultdistributedtracingconfigured">Example
#1: Client and Server with default distributed tracing
configured</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#2:ClientandServerwithnestedtrace">Example #2:
Client and Server with nested trace</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#3:ClientandServertracewithannotations">Example
#3: Client and Server trace with annotations</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#4:ClientandServerwithbinaryannotations(key/value)">Example
#4: Client and Server with binary annotations (key/value)</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#5:ClientandServerwithparalleltrace(involvingthreadpools)">Example
#5: Client and Server with parallel trace (involving thread
pools)</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#6:ClientandServerwithasynchronousJAX-RSservice(server-side
)">Example #6: Client and Server with asynchronous JAX-RS service
(server-side)</h2><p>TBD</p><h2
id="UsingOpenTelemetry-Example#7:ClientandServerwithasynchronousinvocation(client-side)">Example
#7: Client and Server with asynchronous invocation
(client-side)</h2><p>TBD</p><h1
id="UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandJAX-WSsupport">Distributed
Tracing with OpenTelemetry and JAX-WS support</h1><p>TBD</p><h1
id="UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandOSGi">Distributed
Tracing with OpenTelemetry and OSGi</h1><p>TBD</p><h1
id="UsingOpenTelemetry-SpringXML-Configuration">Spring
XML-Configuration</h1><p>TBD</p><h1
id="UsingOpenTelemetry-Usingnon-JAX-RSclients">Using non-JAX-RS
clients</h1><p>TBD</p><p><br clear="none"></p></div>
+</div></div><p>Once the <strong>span processor(s) </strong>and
<strong>sampler</strong> are properly configured, all generated
<strong>spans</strong> are going to be collected and available for analysis
and/or visualization.</p><h1
id="UsingOpenTelemetry-DistributedTracingInAction:UsageScenarios">Distributed
Tracing In Action: Usage Scenarios</h1><p>In the following subsections we are
going to walk through many different scenarios to illustrate the distributed
tracing in action, starting from the simplest ones and finishing with
asynchronous JAX-RS services. All examples assume that configuration
<strong>has been done</strong> (see please <a shape="rect"
href="https://cwiki.apache.org/confluence/display/CXF20DOC/Using+OpenTelemetry#UsingOpenTelemetry-ConfiguringClient"><span
class="confluence-link">Configuring Client</span></a><span
class="confluence-link"> </span> and <a shape="rect"
href="https://cwiki.apache.org/confluence/display/CXF20DOC/Using+OpenTelemetry#UsingOpenTeleme
try-ConfiguringServer"><span class="confluence-link">Configuring
Server</span></a> sections above).</p><h2
id="UsingOpenTelemetry-Example#1:ClientandServerwithdefaultdistributedtracingconfigured">Example
#1: Client and Server with default distributed tracing configured</h2><p>In
the first example we are going to see the effect of using default configuration
on the client and on the server, with only <strong><span style="color:
rgb(0,0,0);">OpenTelemetryClientProvider </span></strong>and <strong><span
style="color: rgb(0,0,0);">OpenTelemetry</span>Provider</strong> registered.
The JAX-RS resource endpoint is pretty basic stubbed method:</p><div
class="code panel pdl" style="border-width: 1px;"><div class="codeContent
panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks() {
+ return Arrays.asList(
+ new Book("Apache CXF Web Service Development", "Naveen Balani, Rajeev
Hathi")
+ );
+}</pre>
+</div></div><p>The client is as simple as that:</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">final Response
response = client
+ .target("http://localhost:8282/books")
+ .request()
+ .accept(MediaType.APPLICATION_JSON)
+ .get();</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong>tracer-client</strong>) and consequent invocation of the
service on the server side (service name<strong> tracer-server</strong>) is
going to generate the following sample traces (taken from <a shape="rect"
class="external-link" href="https://github.com/uber/jaeger-ui"
rel="nofollow">Jaeger UI</a>):</p><p><span
class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img
class="confluence-embedded-image" draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_11-57-14.png"></span></p><h2
id="UsingOpenTelemetry-Example#2:ClientandServerwithnestedtrace">Example #2:
Client and Server with nested trace</h2><p>In this example server-side
implementation of the JAX-RS service is going to call an external system
(simulated as a simple delay of 500ms) within its own span. The client-side
code stays unchanged.</p><div class="code panel pdl" style="border-width: 1px
;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks(@Context final TracerContext tracer)
throws Exception {
+    try(final Scope scope = tracer.startSpan("Calling External
System")) {
+ // Simulating a delay of 500ms required to call external system
+ Thread.sleep(500);
+
+ return Arrays.asList(
+ new Book("Apache CXF Web Service Development", "Naveen Balani,
Rajeev Hathi")
+ );
+ }
+}</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong><span class="label label-default service-filter-label
service-tag-filtered">tracer-client</span></strong>) and consequent invocation
of the service on the server side (service name<strong><span class="label
label-default service-filter-label"> tracer-server</span></strong><span
class="label label-default service-filter-label">)</span> is going to generate
the following sample traces (taken from <a shape="rect" class="external-link"
href="https://github.com/uber/jaeger-ui" rel="nofollow">Jaeger
UI</a>):</p><p><span class="confluence-embedded-file-wrapper
confluence-embedded-manual-size"><img class="confluence-embedded-image"
draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-8-52.png"></span></p><h2
id="UsingOpenTelemetry-Example#3:ClientandServertracewithannotations">Example
#3: Client and Server trace with annotations</h2><p>In this example server-side
implementa
tion of the JAX-RS service is going to add timeline to the active span. The
client-side code stays unchanged.</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks(@Context final TracerContext tracer)
throws Exception {
+ tracer.timeline("Preparing Books");
+ // Simulating some work using a delay of 100ms
+ Thread.sleep(100);
+
+ return Arrays.asList(
+ new Book("Apache CXF Web Service Development", "Naveen Balani, Rajeev
Hathi")
+ );
+}</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong><span class="label label-default service-filter-label
service-tag-filtered">tracer-client</span></strong>) and consequent invocation
of the service on the server side (service name<strong> <span class="label
label-default service-filter-label">traceser-server</span></strong>) is going
to generate the following sample traces (taken from <a shape="rect"
class="external-link" href="https://github.com/uber/jaeger-ui"
rel="nofollow">Jaeger UI</a>):</p><p><span
class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img
class="confluence-embedded-image" draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-13-51.png"></span></p><div
class="confluence-information-macro
confluence-information-macro-information"><span class="aui-icon aui-icon-small
aui-iconfont-info confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p>P
lease notice that timelines are treated as<strong> logs events</strong> in <a
shape="rect" class="external-link" href="https://uber.github.io/jaeger/"
rel="nofollow">Jaeger</a>.</p></div></div><h2
id="UsingOpenTelemetry-Example#4:ClientandServerwithbinaryannotations(key/value)">Example
#4: Client and Server with binary annotations (key/value)</h2><p>In this
example server-side implementation of the JAX-RS service is going to add
key/value annotations to the active span. The client-side code stays
unchanged.</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks(@Context final TracerContext tracer)
throws Exception {
+ final Collection<Book> books = Arrays.asList(
+ new Book("Apache CXF Web Service Development", "Naveen Balani, Rajeev
Hathi")
+ );
+
+ tracer.annotate("# of books", Integer.toString(books.size()));
+ return books;
+}</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong><span class="label label-default service-filter-label
service-tag-filtered">tracer-client</span></strong>) and consequent invocation
of the service on the server side (service name<strong> tracer-<span
class="label label-default service-filter-label">server</span></strong>) is
going to generate the following sample server trace properties (taken from <a
shape="rect" class="external-link" href="https://github.com/uber/jaeger-ui"
rel="nofollow">Jaeger UI</a>):</p><p><span
class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img
class="confluence-embedded-image" draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-19-25.png"></span></p><h2
id="UsingOpenTelemetry-Example#5:ClientandServerwithparalleltrace(involvingthreadpools)">Example
#5: Client and Server with parallel trace (involving thread pools)</h2><p>In
this example server-side implementatio
n of the JAX-RS service is going to offload some work into thread pool and
then return the response to the client, simulating parallel execution. The
client-side code stays unchanged.</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks(@Context final TracerContext tracer)
throws Exception {
+ final Future<Book> book1 = executor.submit(
+ tracer.wrap("Getting Book 1", new Traceable<Book>() {
+ public Book call(final TracerContext context) throws Exception {
+ // Simulating a delay of 100ms required to call external system
+ Thread.sleep(100);
+
+ return new Book("Apache CXF Web Service Development",
+ "Naveen Balani, Rajeev Hathi");
+ }
+ })
+ );
+
+ final Future<Book> book2 = executor.submit(
+ tracer.wrap("Getting Book 2", new Traceable<Book>() {
+ public Book call(final TracerContext context) throws Exception {
+ // Simulating a delay of 100ms required to call external system
+ Thread.sleep(200);
+
+ return new Book("Developing Web Services with Apache CXF and
Axis2",
+ "Kent Ka Iok Tong");
+ }
+ })
+ );
+
+ return Arrays.asList(book1.get(), book2.get());
+}</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong>tracer-<span class="label label-default
service-filter-label service-tag-filtered">client</span></strong>) and
consequent invocation of the service on the server side (process name<strong>
tracer-<span class="label label-default
service-filter-label">server</span></strong>) is going to generate the
following sample traces (taken from <a shape="rect" class="external-link"
href="https://github.com/uber/jaeger-ui" rel="nofollow">Jaeger
UI</a>):</p><p><span class="confluence-embedded-file-wrapper
confluence-embedded-manual-size"><img class="confluence-embedded-image"
draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-21-35.png"></span></p><h2
id="UsingOpenTelemetry-Example#6:ClientandServerwithasynchronousJAX-RSservice(server-side)">Example
#6: Client and Server with asynchronous JAX-RS service (server-side)</h2><p>In
this example server-side implementation of the JAX
-RS service is going to be executed asynchronously. It poses a challenge from
the tracing prospective as request and response are processed in different
threads (in general). At the moment, <a shape="rect"
href="http://cxf.apache.org/">Apache CXF</a> does not support the transparent
tracing spans management (except for default use case) but provides the simple
ways to do that (by letting to transfer spans from thread to thread). The
client-side code stays unchanged.</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public void getBooks(@Suspended final AsyncResponse response, @Context final
TracerContext tracer) throws Exception {
+ tracer.continueSpan(new Traceable<Future<Void>>() {
+ public Future<Void> call(final TracerContext context) throws
Exception {
+ return executor.submit(
+ tracer.wrap("Getting Book", new Traceable<Void>() {
+ public Void call(final TracerContext context) throws
Exception {
+ // Simulating a processing delay of 50ms
+ Thread.sleep(50);
+
+ response.resume(
+ Arrays.asList(
+ new Book("Apache CXF Web Service Development",
"Naveen Balani, Rajeev Hathi")
+ )
+ );
+
+ return null;
+ }
+ })
+ );
+ }
+ });
+}</pre>
+</div></div><p>The actual invocation of the request by the client (with
service name <strong>tracer-<span class="label label-default
service-filter-label service-tag-filtered">client</span></strong>) and
consequent invocation of the service on the server side (service name<strong>
tracer-<span class="label label-default
service-filter-label">server</span></strong>) is going to generate the
following sample traces (taken from <a shape="rect" class="external-link"
href="https://github.com/uber/jaeger-ui" rel="nofollow">Jaeger
UI</a>):</p><p><span class="confluence-embedded-file-wrapper
confluence-embedded-manual-size"><img class="confluence-embedded-image"
draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-23-31.png"></span></p><h2
id="UsingOpenTelemetry-Example#7:ClientandServerwithasynchronousinvocation(client-side)">Example
#7: Client and Server with asynchronous invocation (client-side)</h2><p>In
this example server-side implementation of the JAX-RS ser
vice is going to be the default one:</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">@Produces( {
MediaType.APPLICATION_JSON } )
+@GET
+public Collection<Book> getBooks() {
+ return Arrays.asList(
+ new Book("Apache CXF Web Service Development", "Naveen Balani, Rajeev
Hathi")
+ );
+}</pre>
+</div></div><p>While the JAX-RS client implementation is going to perform the
asynchronous invocation:</p><div class="code panel pdl" style="border-width:
1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default">final
Future<Response> future = client
+ .target("http://localhost:8282/books")
+ .request()
+ .accept(MediaType.APPLICATION_JSON)
+ .async()
+ .get();</pre>
+</div></div><p>In this respect, there is no difference from the caller
prospective however a bit more work is going under the hood to transfer the
active tracing span from JAX-RS client request filter to client response filter
as in general those are executed in different threads (similarly to server-side
asynchronous JAX-RS resource invocation). The actual invocation of the request
by the client (with service name <strong>tracer-<span class="label
label-default service-filter-label
service-tag-filtered">client</span></strong>) and consequent invocation of the
service on the server side (service name<strong> tracer-<span class="label
label-default service-filter-label">server</span></strong>) is going to
generate the following sample traces (taken from <a shape="rect"
class="external-link" href="https://github.com/uber/jaeger-ui"
rel="nofollow">Jaeger UI</a>):</p><p><span
class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img
class="confluence-embedded-image"
draggable="false" width="900"
src="using-opentelemetry.data/image-2023-8-27_12-25-58.png"></span></p><h1
id="UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandJAX-WSsupport">Distributed
Tracing with OpenTelemetry and JAX-WS support</h1><p>TBD</p><h1
id="UsingOpenTelemetry-DistributedTracingwithOpenTelemetryandOSGi">Distributed
Tracing with OpenTelemetry and OSGi</h1><p>TBD</p><h1
id="UsingOpenTelemetry-SpringXML-Configuration">Spring
XML-Configuration</h1><p>TBD</p><h1
id="UsingOpenTelemetry-Usingnon-JAX-RSclients">Using non-JAX-RS
clients</h1><p>TBD</p><p><br clear="none"></p></div>
</div>
<!-- Content -->
</td>