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: site/content/how-to/monitoring/tracing.md
+9-7Lines changed: 9 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -59,11 +59,13 @@ Visit [http://127.0.0.1:16686](http://127.0.0.1:16686) to view the dashboard.
59
59
60
60
## Enabling Tracing
61
61
62
-
Enabling tracing requires two pieces of configuration. The first is a resource called `NginxProxy`, which contains global settings relating to the NGINX data plane. This resource is created and managed by the [cluster operator](https://gateway-api.sigs.k8s.io/concepts/roles-and-personas/), and is referenced in the `parametersRef` field of the GatewayClass. This resource can be created and linked when we install NGINX Gateway Fabric using its helm chart, or it can be added later. In this guide we will install the resource using the helm chart, but will also show what it looks like in case you want to add it after installation.
62
+
Enabling tracing requires two pieces of configuration.
63
+
64
+
-`NginxProxy`: This resource contains global settings relating to the NGINX data plane. It is created and managed by the [cluster operator](https://gateway-api.sigs.k8s.io/concepts/roles-and-personas/), and is referenced in the `parametersRef` field of the GatewayClass. This resource can be created and linked when we install NGINX Gateway Fabric using its helm chart, or it can be added later. In this guide we will install the resource using the helm chart, but will also show what it looks like in case you want to add it after installation.
63
65
64
66
The `NginxProxy` resource contains configuration for the collector, and applies to all Gateways and routes under the GatewayClass. It does not enable tracing, but is a prerequisite to the next piece of configuration.
65
67
66
-
The second piece of configuration is the `ObservabilityPolicy`, which is a [Policy](https://gateway-api.sigs.k8s.io/reference/policy-attachment/) that targets HTTPRoutes or GRPCRoutes. This Policy is created by the [application developer](https://gateway-api.sigs.k8s.io/concepts/roles-and-personas/) and enables tracing for a specific route or routes. It requires the `NginxProxy` resource to exist in order to complete the tracing configuration.
68
+
-`ObservabilityPolicy`: Theis resource is a [Policy](https://gateway-api.sigs.k8s.io/reference/policy-attachment/) that targets HTTPRoutes or GRPCRoutes. It is created by the [application developer](https://gateway-api.sigs.k8s.io/concepts/roles-and-personas/) and enables tracing for a specific route or routes. It requires the `NginxProxy` resource to exist in order to complete the tracing configuration.
67
69
68
70
TODO(sberman): link to reference docs
69
71
@@ -277,14 +279,14 @@ spec:
277
279
name: coffee
278
280
tracing:
279
281
strategy: ratio
280
-
ratio: 50
282
+
ratio: 75
281
283
spanAttributes:
282
284
- key: coffee-key
283
285
value: coffee-value
284
286
EOF
285
287
```
286
288
287
-
This policy attaches to the coffee HTTPRoute and enables ratio-based tracing, where 50% of requests will be sampled. We've also included a span attribute to add extra data to the spans.
289
+
This policy attaches to the coffee HTTPRoute and enables ratio-based tracing, where 75% of requests will be sampled. We've also included a span attribute to add extra data to the spans.
This will send 10 requests. Once complete, let's refresh the Jaeger dashboard. We should now see a service entry called `ngf:default:cafe`, and a few traces. The service name by default is `ngf:<gateway-namespace>:<gateway-name>`.
321
+
Once complete, let's refresh the Jaeger dashboard. We should now see a service entry called `ngf:default:cafe`, and a few traces. The service name by default is `ngf:<gateway-namespace>:<gateway-name>`.
0 commit comments