Ukraine flag We stand with our friends and colleagues in Ukraine. To support Ukraine in their time of need visit this page.

Architecture

Version  2.1 Latest Go to the latest 1.x version

See also:


Jaeger v2 is designed to be a versatile and flexible tracing platform. It can be deployed as a single binary that can be configured to perform different roles within the Jaeger architecture, such as:

  • collector: Receives incoming trace data from applications and writes it into a storage backend.
  • query: Serves the APIs and the user interface for querying and visualizing traces.
  • ingester: Ingests spans from Kafka and writes them into a storage backend; useful when running in a split collector-Kafka-ingester configuration.
  • all-in-one: Collector and query roles in a single process.
  • agent: A host agent or a sidecar that runs next to the application and forwards trace data to the collector. While Jaeger can be configured for this role, we recommend using the standard OpenTelemetry Collectorexternal link instead because you may likely need it to process other types of telemetry (metrics & logs).

Choosing between the all-in-one and the collector/query configurations is a matter of preference. When using external storage backend, both configurations are horizontally scalable, but the collector/query configuration allows to separate the read and write traffic and to scale them independently, as well as to apply different access and security policies.

The all-in-one configuration with in-memory storage is most suitable for development and testing, but it is not recommended for production since the data is lost on restarts. all-in-one with the Badger backend can be used in production, but only for modest data volumes since it is limited to a single instance and cannot be scaled horizontally.

Architecture choices

The two most common deployment options for a scalable Jaeger backend are direct-to-storage and using Kafka as a buffer.

Direct to storage

In this deployment the collectors receive the data from traced applications and write it directly to storage. The storage must be able to handle both average and peak traffic. The collectors may use an in-memory queue to smooth short-term traffic peaks, but a sustained traffic spike may result in dropped data if the storage is not able to keep up.

Architecture

Via Kafka

To prevent data loss between collectors and storage, Kafka can be used as an intermediary, persistent queue. The collectors are configured with Kafka exporters. An additional component, ingester, needs to be deployed to read data from Kafka and save it to storage. Multiple ingesters can be deployed to scale up ingestion; they will automatically partition the load across them. In practice, an ingester is very similar to a collector, only configured with a Kafka receiver instead of RPC-based receivers.

Architecture

With OpenTelemetry Collector

You do not need to use the OpenTelemetry Collector to operate Jaeger, because Jaeger is a customized distribution of the OpenTelemetry Collector with different roles. However, if you already use the OpenTelemetry Collectors, for gathering other types of telemetry or for pre-processing / enriching the tracing data, it can be placed in front of Jaeger in the collection pipeline. The OpenTelemetry Collectors can be run as an application sidecar, as a host agent / daemon, or as a central cluster.

The OpenTelemetry Collector supports Jaeger’s Remote Sampling protocol and can either serve static configurations from config files directly, or proxy the requests to the Jaeger backend (e.g., when using adaptive sampling).

Architecture

OpenTelemetry Collector as a sidecar / host agent

Benefits:

  • The SDK configuration is simplified as both trace export endpoint and sampling config endpoint can point to a local host and not worry about discovering where those services run remotely.
  • Collector may provide data enrichment by adding environment information, like k8s pod name.
  • Resource usage for data enrichment can be distributed across all application hosts.

Downsides:

  • An extra layer of marshaling/unmarshaling the data.

OpenTelemetry Collector as a remote cluster

Benefits:

Downsides:

  • An extra layer of marshaling/unmarshaling the data.

Jaeger Binary

The Jaeger binary is build on top of the OpenTelemetry Collector framework and includes:

  • Official upstream components, such as OTLP Receiver, Batch and Attribute Processor, etc.
  • Upstream components from opentelemetry-collector-contrib, such as Kafka Exporter and Receiver, Tail Sampling Processor, etc.
  • Jaeger own components, such as Jaeger Storage Exporter, Jaeger Query Extension, etc.

Architecture

Jaeger Components

OpenTelemetry Components

Receivers

Processors

Exporters

Connectors

Extensions