From 1103377c449628cf825bfc77e6c1f3762aa7a02b Mon Sep 17 00:00:00 2001 From: Kenneth Mugo Date: Tue, 16 Apr 2024 15:30:40 +0300 Subject: [PATCH] Slight update to docs --- src/Tingle.AspNetCore.ApplicationInsights/README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Tingle.AspNetCore.ApplicationInsights/README.md b/src/Tingle.AspNetCore.ApplicationInsights/README.md index 7c92b3b..e631dfa 100644 --- a/src/Tingle.AspNetCore.ApplicationInsights/README.md +++ b/src/Tingle.AspNetCore.ApplicationInsights/README.md @@ -21,6 +21,8 @@ services.AddHttpContextAccessor(); We've injected the `IHttpContextAccessor` in the DI container so that we can access the `HttpContext` object that contains the HTTP request details. +The request source details will be seen as custom properties of an application insights telemetry record. + ## Add all request headers to application insights telemetry You can send all request headers to application insights by adding the following logic to `Program.cs` or `Startup.cs` file: @@ -32,6 +34,8 @@ services.AddHttpContextAccessor(); We've injected the `IHttpContextAccessor` in the DI container so that we can access the `HttpContext` object that contains the HTTP request details. +The request headers will be seen as custom properties of an application insights telemetry record. + ## Add manual dependency tracking in application insights A dependency is a component that's called by your application. It's typically a service called by using HTTP, a database, or a file system. Application Insights measures the duration of dependency calls and whether it's failing or not, along with information like the name of the dependency. You can investigate specific dependency calls and correlate them to requests and exceptions. The list of dependencies that are automatically tracked can be seen [here](https://learn.microsoft.com/en-us/azure/azure-monitor/app/asp-net-dependencies).