You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: daprdocs/content/en/operations/observability/tracing/otel-collector/open-telemetry-collector-jaeger.md
+31-11Lines changed: 31 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,8 +17,10 @@ Dapr supports writing traces using the OpenTelemetry (OTLP) protocol, and Jaeger
17
17
18
18
The simplest way to start Jaeger is to run the pre-built, all-in-one Jaeger image published to DockerHub and expose the OTLP port:
19
19
20
+
> **Note:** Port 9411 is commonly used by Zipkin. If you have Zipkin running (starts by default when you run `dapr init`), stop the `dapr_zipkin` container first to avoid port conflicts: `docker stop dapr_zipkin`
21
+
20
22
```bash
21
-
docker run --rm --name jaeger \
23
+
docker run -d --rm --name jaeger \
22
24
-p 16686:16686 \
23
25
-p 4317:4317 \
24
26
-p 4318:4318 \
@@ -27,7 +29,19 @@ docker run --rm --name jaeger \
27
29
cr.jaegertracing.io/jaegertracing/jaeger:2.11.0
28
30
```
29
31
30
-
Next, create the following `config.yaml` file locally:
32
+
You can also view the logs from the jaeger container using:
33
+
34
+
```bash
35
+
docker logs jaeger
36
+
```
37
+
38
+
### Configure Dapr for tracing
39
+
40
+
You have two options to configure Dapr to send traces to Jaeger V2:
41
+
42
+
#### Option 1: Use a custom config file
43
+
44
+
Create a `config.yaml` file with the following content:
31
45
32
46
> **Note:** Because you are using the Open Telemetry protocol to talk to Jaeger, you need to fill out the `otel` section of the tracing configuration and set the `endpointAddress` to the address of the Jaeger container.
33
47
@@ -54,6 +68,10 @@ the `--config` option. For example:
54
68
dapr run --app-id myapp --app-port 3000 node app.js --config config.yaml
55
69
```
56
70
71
+
#### Option 2: Update the default Dapr config (development environment)
72
+
73
+
Alternatively, in your development environment, navigate to your [local Dapr components directory](https://docs.dapr.io/getting-started/install-dapr-selfhost/#step-5-verify-components-directory-has-been-initialized) and update the default `config.yaml` file with the OTLP configuration above. This way, all Dapr applications will use the Jaeger V2 tracing configuration by default without needing to specify the `--config` flag each time.
74
+
57
75
### View traces
58
76
59
77
To view traces in your browser, go to `http://localhost:16686` to see the Jaeger UI.
@@ -77,20 +95,22 @@ Jaeger V2 can be deployed using the OpenTelemetry Operator for simplified manage
77
95
78
96
#### Installation
79
97
80
-
1. **Install cert-manager** to manage certificates:
Verify that all resources in the `cert-manager` namespace are ready.
98
+
> **Note:** In order for the API server to communicate with the webhook component of the operator, the webhook requires a TLS certificate that the API server is configured to trust. There are a few different ways you can use to generate/configure the required TLS certificate detailed in the [otel operator chart docs](https://github.com/open-telemetry/opentelemetry-helm-charts/tree/main/charts/opentelemetry-operator#tls-certificate-requirement)
99
+
100
+
For simplicity you can use Helm to create an automatically generated self-signed certificate.
Confirm that all resources in the `opentelemetry-operator-system` namespace are ready.
91
111
92
112
1. **Deploy a Jaeger V2 instance with in-memory storage**:
93
-
Apply the following configuration to create a Jaeger V2 instance:
113
+
Create a file named `jaeger-inmemory.yaml` with the following configuration:
94
114
```yaml
95
115
apiVersion: opentelemetry.io/v1beta1
96
116
kind: OpenTelemetryCollector
@@ -139,7 +159,7 @@ Jaeger V2 can be deployed using the OpenTelemetry Operator for simplified manage
139
159
140
160
Create a Dapr configuration file to enable tracing and export the sidecar traces directly to the Jaeger V2 instance.
141
161
142
-
1. Create a configuration file (e.g., `tracing.yaml`) with the following content, updating the `namespace` and `otel.endpointAddress` to match your Jaeger V2 instance:
162
+
1. Create a configuration file (for example `tracing.yaml`) with the following content, updating the `namespace` and `otel.endpointAddress` to match your Jaeger V2 instance:
143
163
```yaml
144
164
apiVersion: dapr.io/v1alpha1
145
165
kind: Configuration
@@ -190,7 +210,7 @@ That’s it! There’s no need to include the OpenTelemetry SDK or instrument yo
190
210
To view Dapr sidecar traces, port-forward the Jaeger V2 service and open the UI:
0 commit comments