• This repository has been archived on 01/Jul/2022
  • Stars
    star
    491
  • Rank 89,636 (Top 2 %)
  • Language
    Java
  • License
    Other
  • Created over 8 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

🛑 This library is DEPRECATED!

Build Status Coverage Status Released Version javadoc FOSSA Status

🛑 This library is DEPRECATED!

v1.8.1 is the final release. No new pull requests are accepted.

We urge all users to migrate to OpenTelemetry. Please refer to the notice in the documentation for details.

Jaeger's Tracing Instrumentation Library for Java

  • Intended to be used with Jaeger backend, but can also be configured to send traces to Zipkin.
  • Implements OpenTracing Java API.
  • Supports Java 1.8 and above

Package rename to io.jaegertracing

The group ID com.uber.jaeger has been deprecated and moved to a different repository. Please switch to io.jaegertracing, as the old group ID will be maintained only for bug fixes.

Contributing and Developing

Please see CONTRIBUTING.md.

Core Modules

Click through for more detailed docs on specific modules.

  • jaeger-client: the module that instrumented applications should usually include
  • jaeger-core: the core implementation of the OpenTracing API Java Docs
  • jaeger-thrift: set of components that send data to the backend

Add-on Modules

Importing Dependencies

All artifacts are published to Maven Central. Snapshot artifacts are also published to Sonatype. Follow these instructions to add the snapshot repository to your build system.

Please use the latest version: Released Version

In the usual case, you just need to include the following dependency to your project:

<dependency>
    <groupId>io.jaegertracing</groupId>
    <artifactId>jaeger-client</artifactId>
    <version>$jaegerVersion</version>
</dependency>

This will bring a concrete sender, such as jaeger-thrift, as well as the jaeger-tracerresolver and jaeger-core.

Thrift version conflicts

The Jaeger Java Client uses org.apache.thrift:libthrift:0.11.0. By default, declaring a dependency on the jaeger-thrift module will bring a non-shaded version of Thrift (and others). A shaded version of the dependency is available with the classifier shadow.

Instantiating the Tracer

Please see jaeger-core/README.

Testing

When testing tracing instrumentation it is often useful to make sure that all spans are being captured, which is not the case in production configurations where heavy sampling is applied by default. The following configuration can be provided to affect which sampling is applied to the new traces:

sampler:
   type: const # can either be const, probabilistic, or ratelimiting
   param: 1  # can either be an integer, a double, or an integer

The valid values for type are:

  • const: configures a sampler that always makes the same decision for new traces depending on the param: always no for param=0, always yes otherwise.
  • probabilistic: configures a sampler that samples traces with probability equal to param (must be between 0.0 and 1.0)
  • ratelimiting: configures a samlper that samples traces with a certain rate per second equal to param

Debug Traces (Forced Sampling)

Programmatically

The OpenTracing API defines a sampling.priority standard tag that can be used to affect the sampling of a span and its children:

import io.opentracing.tag.Tags;

Tags.SAMPLING_PRIORITY.set(span, 1);

Via HTTP Headers

Jaeger Tracer also understands a special HTTP Header jaeger-debug-id, which can be set in the incoming request, e.g.

curl -H "jaeger-debug-id: some-correlation-id" http://myhost.com

When Jaeger sees this header in the request that otherwise has no tracing context, it ensures that the new trace started for this request will be sampled in the "debug" mode (meaning it should survive all downsampling that might happen in the collection pipeline), and the root span will have a tag as if this statement was executed:

span.setTag("jaeger-debug-id", "some-correlation-id")

This allows using Jaeger UI to find the trace by this tag.

License

Apache 2.0 License.

More Repositories

1

jaeger

CNCF Jaeger, a Distributed Tracing Platform
Go
20,138
star
2

jaeger-client-go

🛑 This library is DEPRECATED!
Go
1,382
star
3

jaeger-ui

Web UI for Jaeger
JavaScript
1,110
star
4

jaeger-operator

Jaeger Operator for Kubernetes simplifies deploying and running Jaeger on Kubernetes.
Go
1,012
star
5

jaeger-client-node

🛑 This library is DEPRECATED!
JavaScript
552
star
6

jaeger-kubernetes

Support for deploying Jaeger into Kubernetes
Java
447
star
7

jaeger-client-python

🛑 This library is DEPRECATED!
Python
408
star
8

jaeger-client-csharp

🛑 This library is DEPRECATED!
C#
303
star
9

helm-charts

Helm Charts for Jaeger backend
Mustache
265
star
10

jaeger-clickhouse

Jaeger ClickHouse storage plugin implementation
Go
251
star
11

jaeger-client-cpp

🛑 This library is DEPRECATED!
C++
138
star
12

spark-dependencies

Spark job for dependency links
Java
121
star
13

docker-protobuf

An all-inclusive protoc Docker image for the Jaeger project
Dockerfile
93
star
14

jaeger-idl

A set of shared data model definitions used by Jaeger components.
Thrift
80
star
15

jaeger-analytics-flink

Big data analytics for Jaeger using Apache Flink
Java
68
star
16

documentation

Documentation/website for the Jaeger Distributed Tracing project.
HTML
67
star
17

jaeger-lib

A collection of shared infrastructure libraries used by different components of Jaeger.
Go
67
star
18

jaeger-openshift

Support for deploying Jaeger into OpenShift
Groovy
57
star
19

jaeger-analytics-java

Data analytics pipeline and models for tracing data
Java
45
star
20

jaeger-client-javascript

Note: this SDK is not implemented yet, see https://github.com/jaegertracing/jaeger-client-javascript/issues/1.
JavaScript
32
star
21

jaeger-performance

Home of the Jaeger Performance tests
Java
21
star
22

jaeger-opentelemetry-collector

Experimental: components needed to build Jaeger on top of OpenTelemetry Collector
Makefile
12
star
23

jaeger-otelcol

Jaeger's OpenTelemetry Collector distribution
Go
7
star
24

legacy-client-java

Legacy com.uber.jaeger java client
Java
5
star
25

jaeger-vscode

VSCode extension for Jaeger
TypeScript
5
star
26

security-audits

Jaeger security audits
3
star
27

jaeger-opentelemetry-releases

Go
3
star
28

vertx-create-span

Demo application used in e2e tests for the Jaeger Operator
Java
3
star
29

artwork

Jaeger Logo and Artwork
2
star