user42012
user42012

Reputation: 852

Azure Application Insights showing duplicate entries

We are using Azure Function App, Azure SQL server and API management a very simply solution and we are reporting all our telemetry back to Application Insights. Right now we are trying to review some performance issue and what we are observing is that Application Insights is showing duplicate records (screenshot below). Anyone know how we can avoid this duplicate entries and have a clean hierarchical flow of telemetry data?

enter image description here

Update 01/04/2022: Following is the list of Dlls from the Function App and I am not sure if this is the one causing duplication

enter image description here

UPDATE: 01/05/2022: We created a new Application Insights Instance and just created out of the box Function App From Azure portal and attached this instance of App Insights (no custom code nothing just sample code) and still we see DUPLICATE telemetry for that new function App as shown below from the App Insights logs:

enter image description here

Upvotes: 8

Views: 6965

Answers (1)

Serhat
Serhat

Reputation: 638

If your application insights is workspace-based, the app logs are stored in the workspace, AI SDK will collect them once, and diagnostics setting will collect them again, so there is duplicate logs in the workspace. Here, you can delete the diagnostic setting, or remove the destination of the workspace which is part of diagnostic setting.

Kindly check if this is the case for you.

Referenced from: https://learn.microsoft.com/en-us/answers/questions/883344/application-insights-duplicate-telemetry

If you're using terraform and have diagnostics setting resource, removing log_analytics_workspace_id = data.azurerm_log_analytics_workspace.log_analytics.id might also help.

Upvotes: 4

Related Questions