An MicroProfile-OpenTracing implementation
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
pom.xml [maven-release-plugin] prepare for next development iteration Nov 19, 2018


Semaphore CI License

SmallRye OpenTracing

SmallRye OpenTracing is an implementation of meant to be reusable for different vendors.

How to use

The following components have to be added to deployment to pass microprofile-opentracing-tck:

Server side JAX-RS

Server side JAX-RS tracing integration is provided by JAX-RS SmallRyeTracingDynamicFeature and servlet filter SpanFinishingFilter which finishes the span started in JAX-RS filter.

The installation is JAX-RS and server implementation specific. For example in RestEasy DynamicFeature it can be enabled by specifying resteasy.providers in servlet context init parameters. The following code snippet demonstrates possible installation.

public class ServletContextTracingInstaller implements ServletContextListener {

  public void contextInitialized(ServletContextEvent servletContextEvent) {
    ServletContext servletContext = servletContextEvent.getServletContext();
    servletContext.setInitParameter("resteasy.providers", SmallRyeTracingDynamicFeature.class.getName());

    Dynamic filterRegistration = servletContext.addFilter("tracingFilter", new SpanFinishingFilter());
    filterRegistration.addMappingForUrlPatterns(EnumSet.allOf(DispatcherType.class), true, "*");

Client side JAX-RS

Vendor has to implement ClientTracingRegistrarProvider and specify it in META-INF/services/org.eclipse.microprofile.opentracing.ClientTracingRegistrarProvider.

This project provides SmallRyeClientTracingFeature with tracing integration. The feature has to be registered to ClientBuilder in vendor specific implementation of ClientTracingRegistrarProvider. Client side tracing usually requires more components, for example OpenTracing-aware AsyncExecutor.


The @Traced aspects of the specification is provided by the OpenTracingInterceptor, from the OpenTracing Contrib Java Interceptors project.

Tracer producer

Vendor has to provide CDI tracer producer. It is not provided by this library as the tracer resolution is not defined by MicroProfile specification.


mvn clean install

Debug can be enabled in arquillian.xml configuration file.


The release process is done automatically via CI integration. For more information see Release process. Before releasing make sure that the current version in pom.xml matches specification version. To update the version run mvn --batch-mode release:update-versions -DdevelopmentVersion=1.2.0-SNAPSHOT. Now the artifact can be release for specification version 1.2.