Closed hafeefshaik closed 2 years ago
@hafeefshaik, Profiler option is enabled only when application insights is turned on in Recommended mode. Profiler cannot be enabled through SDK. Please follow instruction in this article
@rajkumar-rangaraj I tried both recommended and basic. The behaviour is same. Can you please help how can I enable snapshot and sql?
I have the same problem. The message implies that we have to enable the .NET SDK on the "APM instance" - I don't know how we do that, but I don't think it's related to our code.
In our case we're running an ASP.NET Core web app in an App Service. Stack is set to .NET Core, Platform is 32-bit.
Hello @hafeefshaik / @pdonovan , this is the github repo for the .NET Application Insights SDK. CLR profilers cannot be enabled through .NET SDK. In app service this is enabled through Application Insights Agent. They don't have a public repository. To get support you'll need to open a support ticket from your Application Insights resource.
This issue is stale because it has been open 300 days with no activity. Remove stale label or comment or this will be closed in 7 days.
Change the Collection level to "Recommended", then you will be able to switch ON the Profiler
This issue is stale because it has been open 300 days with no activity. Remove stale label or this will be closed in 7 days. Commenting will instruct the bot to automatically remove the label.
I think the real issue here is that the hint referees to the .NET SDK being disabled, while it actually isn't. If the wording would refer to the collection level, there wouldn't be any confusion.
For those who are here years later, I had to toggle "Collection level" to disabled and back to recommended to see the options to enable and disable other options. This is complete a bug on Azure's part and you will not find this solution in any of the tutorials listed above.
For Apps running on a Linux App Service Plan you need to enable profiling within your code by adding the Nuget package dotnet add package Microsoft.ApplicationInsights.Profiler.AspNetCore
and adding builder.Services.AddServiceProfiler();
to Program.cs
https://learn.microsoft.com/en-us/azure/azure-monitor/profiler/profiler-aspnetcore-linux?tabs=enablement#set-up-the-project-locally
Describe your environment. Describe any aspect of your environment relevant to the question: SDK version: Latest on nuget. .NET runtime version (.NET 4.7.2): Hosting Info (Azure WebApps): Platform and OS version: Windows
How can i enable below application insights setting through .Net SDK
Below is my application insights config.
<?xml version="1.0" encoding="utf-8"?>