Skip to content

Commit

Permalink
remove application insights from API
Browse files Browse the repository at this point in the history
  • Loading branch information
EdiWang committed Oct 25, 2023
1 parent 26735ba commit f1c91ab
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
1 change: 0 additions & 1 deletion src/API/Elf.Api/Elf.Api.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
<PackageReference Include="Microsoft.Identity.Web" Version="2.15.1" />
<PackageReference Include="Microsoft.FeatureManagement.AspNetCore" Version="2.6.1" />
<PackageReference Include="Microsoft.Azure.AppConfiguration.AspNetCore" Version="6.1.0" />
<PackageReference Include="Microsoft.ApplicationInsights.AspNetCore" Version="2.21.0" />

<PackageReference Include="Microsoft.Extensions.Caching.StackExchangeRedis" Version="8.0.0-rc.2.23480.2" />
<PackageReference Include="Microsoft.Extensions.Http.Polly" Version="8.0.0-rc.2.23480.2" />
Expand Down
6 changes: 0 additions & 6 deletions src/API/Elf.Api/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
using Elf.Api.Data;
using Elf.Api.Features;
using Elf.Api.TokenGenerator;
using Microsoft.ApplicationInsights.Extensibility;
using Microsoft.ApplicationInsights.Extensibility.Implementation;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.AspNetCore.HttpOverrides;
using Microsoft.EntityFrameworkCore;
Expand Down Expand Up @@ -169,7 +167,6 @@ void ConfigureServices(IServiceCollection services)
{
services.AddAzureAppConfiguration();
}
services.AddApplicationInsightsTelemetry();

// Elf
services.AddSingleton<CannonService>();
Expand Down Expand Up @@ -211,9 +208,6 @@ void ConfigureMiddleware()
app.UseCors("local");
app.UseSwagger();
app.UseSwaggerUI();
var tc = app.Services.GetRequiredService<TelemetryConfiguration>();
tc.DisableTelemetry = true;
TelemetryDebugWriter.IsTracingDisabled = true;
app.UseDeveloperExceptionPage();
}
else
Expand Down

0 comments on commit f1c91ab

Please sign in to comment.