File tree Expand file tree Collapse file tree 1 file changed +20
-16
lines changed
website/src/docs/hotchocolate/v13/server Expand file tree Collapse file tree 1 file changed +20
-16
lines changed Original file line number Diff line number Diff line change @@ -268,14 +268,16 @@ builder.Logging.AddOpenTelemetry(
268
268
b .SetResourceBuilder (ResourceBuilder .CreateDefault ().AddService (" Demo" ));
269
269
});
270
270
271
- builder .Services .AddOpenTelemetryTracing (
272
- b =>
273
- {
274
- b .AddHttpClientInstrumentation ();
275
- b .AddAspNetCoreInstrumentation ();
276
- b .AddHotChocolateInstrumentation ();
277
- b .AddJaegerExporter ();
278
- });
271
+ builder .Services
272
+ .AddOpenTelemetryTracing ()
273
+ .WithTracing (
274
+ b =>
275
+ {
276
+ b .AddHttpClientInstrumentation ();
277
+ b .AddAspNetCoreInstrumentation ();
278
+ b .AddHotChocolateInstrumentation ();
279
+ b .AddJaegerExporter ();
280
+ });
279
281
```
280
282
281
283
` AddHotChocolateInstrumentation ` will register the Hot Chocolate instrumentation events with OpenTelemetry.
@@ -296,14 +298,16 @@ builder.Services
296
298
builder .Logging .AddOpenTelemetry (
297
299
b => b .SetResourceBuilder (ResourceBuilder .CreateDefault ().AddService (" Demo" )));
298
300
299
- builder .Services .AddOpenTelemetryTracing (
300
- b =>
301
- {
302
- b .AddHttpClientInstrumentation ();
303
- b .AddAspNetCoreInstrumentation ();
304
- b .AddHotChocolateInstrumentation ();
305
- b .AddJaegerExporter ();
306
- });
301
+ builder .Services
302
+ .AddOpenTelemetryTracing ()
303
+ .WithTracing (
304
+ b =>
305
+ {
306
+ b .AddHttpClientInstrumentation ();
307
+ b .AddAspNetCoreInstrumentation ();
308
+ b .AddHotChocolateInstrumentation ();
309
+ b .AddJaegerExporter ();
310
+ });
307
311
308
312
var app = builder .Build ();
309
313
app .MapGraphQL ();
You can’t perform that action at this time.
0 commit comments