Hello Tom,
When you release a new version of your .NET Framework Web API to Azure App Service and notice that Application Insights is no longer logging as many requests as before, but your app still seems to be running fine, it’s usually a configuration or instrumentation issue.
Here are a few things to check:
- Instrumentation Key / Connection String: Make sure your Application Insights instrumentation key or connection string is still correctly set in your app settings or configuration files. Sometimes, these can get overwritten or missed during deployment.
- Telemetry Modules: If you’re using custom telemetry modules or have changed your Application Insights configuration, double-check that all the necessary modules are enabled and configured. For example, if you want to track requests, the
RequestTrackingTelemetryModule
should be active. - Health Check Filtering: Azure App Service health checks can sometimes be filtered out from Application Insights, especially if you’ve updated your configuration or are using a newer SDK version. Check if there are any filters or sampling settings that might be excluding these requests.
- Sampling Settings: Application Insights uses sampling to reduce the amount of telemetry sent. If your sampling rate is set too high, you might not see all requests. Review your sampling configuration to ensure it’s not filtering out too much data.
- SDK Version: If you updated the Application Insights SDK or made changes to your dependencies, make sure you’re using a compatible version and that it’s properly initialized in your application.
- Restart the App Service: Sometimes, a simple restart of your Azure App Service can resolve telemetry issues after a deployment.
Summary:
- Double-check your Application Insights configuration and keys.
- Review your telemetry modules and sampling settings.
- Make sure nothing is filtering out the requests you want to see.
- Restart your app if you haven’t already.
If you’ve checked all these and still have issues, try enabling verbose logging for Application Insights to see if there are any errors or warnings during telemetry submission.
Hope this helps!