From aad90086ee7dce269dd16470c0b51e70d7c6d93d Mon Sep 17 00:00:00 2001 From: Enkidu93 Date: Thu, 21 Sep 2023 09:38:35 -0400 Subject: [PATCH] Added gRPC instrumentation & moved package references --- src/SIL.Machine.AspNetCore/SIL.Machine.AspNetCore.csproj | 4 ---- src/SIL.Machine.Serval.EngineServer/Program.cs | 9 ++++++--- .../SIL.Machine.Serval.EngineServer.csproj | 6 ++++++ src/SIL.Machine.Serval.JobServer/Program.cs | 9 ++++++--- .../SIL.Machine.Serval.JobServer.csproj | 5 +++++ 5 files changed, 23 insertions(+), 10 deletions(-) diff --git a/src/SIL.Machine.AspNetCore/SIL.Machine.AspNetCore.csproj b/src/SIL.Machine.AspNetCore/SIL.Machine.AspNetCore.csproj index 72c0490a4..9cec53cad 100644 --- a/src/SIL.Machine.AspNetCore/SIL.Machine.AspNetCore.csproj +++ b/src/SIL.Machine.AspNetCore/SIL.Machine.AspNetCore.csproj @@ -34,10 +34,6 @@ - - - - diff --git a/src/SIL.Machine.Serval.EngineServer/Program.cs b/src/SIL.Machine.Serval.EngineServer/Program.cs index e5e578ee6..6ba9b9a5c 100644 --- a/src/SIL.Machine.Serval.EngineServer/Program.cs +++ b/src/SIL.Machine.Serval.EngineServer/Program.cs @@ -14,9 +14,12 @@ .AddOpenTelemetry() .WithTracing(builder => { - builder.AddAspNetCoreInstrumentation().AddConsoleExporter(); - builder.AddHttpClientInstrumentation().AddConsoleExporter(); - builder.AddSource("MongoDB.Driver.Core.Extensions.DiagnosticSources").AddConsoleExporter(); + builder + .AddAspNetCoreInstrumentation() + .AddHttpClientInstrumentation() + .AddGrpcClientInstrumentation() + .AddSource("MongoDB.Driver.Core.Extensions.DiagnosticSources") + .AddConsoleExporter(); }); var app = builder.Build(); diff --git a/src/SIL.Machine.Serval.EngineServer/SIL.Machine.Serval.EngineServer.csproj b/src/SIL.Machine.Serval.EngineServer/SIL.Machine.Serval.EngineServer.csproj index 2a12ab8da..9a6962da2 100644 --- a/src/SIL.Machine.Serval.EngineServer/SIL.Machine.Serval.EngineServer.csproj +++ b/src/SIL.Machine.Serval.EngineServer/SIL.Machine.Serval.EngineServer.csproj @@ -9,6 +9,12 @@ + + + + + + diff --git a/src/SIL.Machine.Serval.JobServer/Program.cs b/src/SIL.Machine.Serval.JobServer/Program.cs index 2b04cb2ad..c39d250c1 100644 --- a/src/SIL.Machine.Serval.JobServer/Program.cs +++ b/src/SIL.Machine.Serval.JobServer/Program.cs @@ -13,9 +13,12 @@ .AddOpenTelemetry() .WithTracing(builder => { - builder.AddAspNetCoreInstrumentation().AddConsoleExporter(); - builder.AddHttpClientInstrumentation().AddConsoleExporter(); - builder.AddSource("MongoDB.Driver.Core.Extensions.DiagnosticSources").AddConsoleExporter(); + builder + .AddAspNetCoreInstrumentation() + .AddHttpClientInstrumentation() + .AddGrpcClientInstrumentation() + .AddSource("MongoDB.Driver.Core.Extensions.DiagnosticSources") + .AddConsoleExporter(); }); var app = builder.Build(); diff --git a/src/SIL.Machine.Serval.JobServer/SIL.Machine.Serval.JobServer.csproj b/src/SIL.Machine.Serval.JobServer/SIL.Machine.Serval.JobServer.csproj index c33369c73..0e6059cc0 100644 --- a/src/SIL.Machine.Serval.JobServer/SIL.Machine.Serval.JobServer.csproj +++ b/src/SIL.Machine.Serval.JobServer/SIL.Machine.Serval.JobServer.csproj @@ -12,6 +12,11 @@ + + + + +