You are configuring Application Insights for a .NET Core web application deployed to Azure App Service. The application must capture telemetry for all HTTP requests, exceptions, and dependency calls with minimal code changes. What should you do?
Trap 1: Configure diagnostics logging in the App Service and stream logs to…
Diagnostics logging captures only logs, not full telemetry.
Trap 2: Install the Microsoft.ApplicationInsights.AspNetCore NuGet package…
This requires code changes, which the scenario wants to minimize.
Trap 3: Add the Application Insights JavaScript SDK to each page.
This only captures client-side telemetry, not server-side.
- A
Enable the Application Insights site extension in the App Service 'Application Insights' blade.
The site extension enables auto-instrumentation with no code changes.
- B
Configure diagnostics logging in the App Service and stream logs to Application Insights.
Why wrong: Diagnostics logging captures only logs, not full telemetry.
- C
Install the Microsoft.ApplicationInsights.AspNetCore NuGet package and add services.AddApplicationInsightsTelemetry() in Startup.cs.
Why wrong: This requires code changes, which the scenario wants to minimize.
- D
Add the Application Insights JavaScript SDK to each page.
Why wrong: This only captures client-side telemetry, not server-side.