Application monitoring for Azure App Service overview
It's now easier than ever to enable monitoring on your web applications based on ASP.NET, ASP.NET Core, Java, and Node.js running on Azure App Service. Previously, you needed to manually instrument your app, but the latest extension/agent is now built into the App Service image by default.
Enable Application Insights
There are two ways to enable monitoring for applications hosted on App Service:
Auto-instrumentation application monitoring (ApplicationInsightsAgent).
This method is the easiest to enable, and no code change or advanced configurations are required. It's often referred to as "runtime" monitoring. For App Service, we recommend that at a minimum you enable this level of monitoring. Based on your specific scenario, you can evaluate whether more advanced monitoring through manual instrumentation is needed.
For a complete list of supported auto-instrumentation scenarios, see Supported environments, languages, and resource providers.
The following platforms are supported for auto-instrumentation monitoring:
Manually instrumenting the application through code by installing the Application Insights SDK.
This approach is much more customizable, but it requires the following approaches: SDK for .NET Core, .NET, Node.js, Python, and a standalone agent for Java. This method also means you must manage the updates to the latest version of the packages yourself.
If you need to make custom API calls to track events/dependencies not captured by default with auto-instrumentation monitoring, you need to use this method. To learn more, see Application Insights API for custom events and metrics.
If both auto-instrumentation monitoring and manual SDK-based instrumentation are detected, in .NET only the manual instrumentation settings are honored, while in Java only the auto-instrumentation are emitting the telemetry. This practice is to prevent duplicate data from being sent.
Snapshot Debugger and Profiler are only available in .NET and .NET Core.
This section contains the release notes for Azure Web Apps Extension for runtime instrumentation with Application Insights.
To find which version of the extension you're currently using, go to
- .NET/.NET Core: Upgraded to ApplicationInsights .NET SDK to 2.20.1.
- Separate .NET/.NET Core, Java and Node.js package into different App Service Windows Site Extension.
- JAVA extension: Upgraded to Java Agent 3.2.0 from 2.5.1.
- Node.js extension: Updated AI SDK to 2.1.8 from 2.1.7. Added support for User and System assigned Azure AD Managed Identities.
- .NET Core: Added self-contained deployments and .NET 6.0 support using .NET Startup Hook.
- Node.js extension: Updated AI SDK to 2.1.7 from 2.1.3.
- .NET Core: Removed out-of-support version (2.1). Supported versions are 3.1 and 5.0.
- JAVA extension: Upgraded to Java Agent 3.1.1 (GA) from 3.0.2.
- Node.js extension: Updated AI SDK to 2.1.3 from 1.8.8.
- .NET Core: Added .NET Core 5.0 support.
- JAVA extension: upgraded to Java Agent 3.0.2 (GA) from 2.5.1.
- Node.js extension: Updated AI SDK to 1.8.8 from 1.8.7.
- .NET Core: Removed out-of-support versions (2.0, 2.2, 3.0). Supported versions are 2.1 and 3.1.
- AppSvc Windows extension: Made .NET Core work with any version of System.Diagnostics.DiagnosticSource.dll.
- AppSvc Windows extension: Enabled Inter-op with AI SDK in .NET Core.
- AppSvc Windows extension: Added .NET Core 3.1 support.
- .NET, .NET core, Java, and Node.js agents and the Windows Extension: Support for sovereign clouds. Connections strings can be used to send data to sovereign clouds.
- The ASP.NET Core agent fixed an issue with the Application Insights SDK. If the runtime loaded the incorrect version of
System.Diagnostics.DiagnosticSource.dll, the codeless extension doesn't crash the application and backs off. To fix the issue, customers should remove
System.Diagnostics.DiagnosticSource.dllfrom the bin folder or use the older version of the extension by setting
ApplicationInsightsAgent_EXTENSIONVERSION=2.8.24. If they don't, application monitoring isn't enabled.
- ASP.NET Core agent: Fixed issue related to updated Application Insights SDK. The agent doesn't try to load
AiHostingStartupif the ApplicationInsights.dll is already present in the bin folder. It resolves issues related to reflection via Assembly<AiHostingStartup>.GetTypes().
- Known issues: Exception
System.IO.FileLoadException: Could not load file or assembly 'System.Diagnostics.DiagnosticSource, Version=126.96.36.199, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'could be thrown if another version of
DiagnosticSourcedll is loaded. It could happen, for example, if
System.Diagnostics.DiagnosticSource.dllis present in the publish folder. As mitigation, use the previous version of extension by setting app settings in app services: ApplicationInsightsAgent_EXTENSIONVERSION=2.8.24.
- Repackaged version of 2.8.21.
- Added ASP.NET Core 3.0 codeless monitoring support.
- Updated ASP.NET Core SDK to 2.8.0 for runtime versions 2.1, 2.2 and 3.0. Apps targeting .NET Core 2.0 continue to use 2.1.1 of the SDK.
- Updated ASP.NET Core SDK version from 2.3.0 to the latest (2.6.1) for apps targeting .NET Core 2.1, 2.2. Apps targeting .NET Core 2.0 continue to use 2.1.1 of the SDK.
Support for ASP.NET Core 2.2 apps.
Fixed a bug in ASP.NET Core extension causing injection of SDK even when the application is already instrumented with the SDK. For 2.1 and 2.2 apps, the presence of ApplicationInsights.dll in the application folder now causes the extension to back off. For 2.0 apps, the extension backs off only if ApplicationInsights is enabled with a
Permanent fix for incomplete HTML response for ASP.NET Core apps. This fix is now extended to work for .NET Core 2.2 apps.
Fixed ASP.NET Core extension bug that caused injection even if ikey wasn't present.
Fixed a bug in the SDK version prefix logic that caused an incorrect SDK version in telemetry.
Added SDK version prefix for ASP.NET Core apps to identify how telemetry was collected.
Fixed SCM- ApplicationInsights page to correctly show the version of the pre-installed extension.
- Fix for incomplete HTML response for ASP.NET Core apps.
Learn how to enable auto-instrumentation application monitoring for your .NET Core, .NET, Java, or Nodejs application running on App Service.
Submit and view feedback for