Application Insights 自部署到 Azure Web 应用程序后没有数据
Application Insights No data since deployed to Azure web app
我正在使用 Azure Application Insights。
在按照官方文档进行一些配置步骤之后,我发现我的应用程序洞察力在我的本地构建上运行良好。 Request、Exception、Dependency、Custom Event的数据全部出现在azure portal中
但是,一旦我将其部署到 Azure Web 应用程序,我就无法在 Azure 门户中看到任何 Application Insights 数据。
我已经根据本文的 "No (server) data since I published the app to my server" 部分验证了 Application Insights Dll 和 Microsoft.Diagnostics.Tracing.EventSource.dll 都已复制到 azure:
https://azure.microsoft.com/en-us/documentation/articles/app-insights-asp-net-troubleshoot-no-data/#q03
其他一些奇怪的事情是,当我远程调试我的 azure web 应用程序时,我发现所有 TelemetryClient 都出现 "not configured",但是我的 Instrumentation 密钥正确写入 ApplicationInsights.config
还有一件事是,当我像这样更改代码时:
var client = new TelemetryClient();
client.Context.InstrumentationKey = "The Key";
client.TrackEvent("TestEvent");
自定义事件出现在 Azure 门户中。但其他数据如请求、异常、依赖项不会自动记录在门户中。
我的申请有什么问题?
听起来您正在记录遥测数据,您可以控制 TelemetryClient - 就像上面的代码示例一样。
考虑到这一点,您需要检查以下几点:
- applicationinsights.config 已使用您的检测密钥进行配置。
- applicationinsights.config 正在部署到 WebApps
- 所有必要的遥测模块都在您的web.config
中
由于您是在本地接收遥测数据,我想说这就像您不部署 applicationinsights.config 文件一样简单。
在azure支持工程师的帮助下,问题已经解决
原因是在azure portal的App Setting中,有一个config sets "MOBILESERVICESDOTNET_EXTENSION_VERSION" = 1.0.478
删除此配置后,一切正常
但我仍然不确定其根本原因。为什么这个配置会造成这么多麻烦?
我正在使用 Azure Application Insights。 在按照官方文档进行一些配置步骤之后,我发现我的应用程序洞察力在我的本地构建上运行良好。 Request、Exception、Dependency、Custom Event的数据全部出现在azure portal中
但是,一旦我将其部署到 Azure Web 应用程序,我就无法在 Azure 门户中看到任何 Application Insights 数据。
我已经根据本文的 "No (server) data since I published the app to my server" 部分验证了 Application Insights Dll 和 Microsoft.Diagnostics.Tracing.EventSource.dll 都已复制到 azure: https://azure.microsoft.com/en-us/documentation/articles/app-insights-asp-net-troubleshoot-no-data/#q03
其他一些奇怪的事情是,当我远程调试我的 azure web 应用程序时,我发现所有 TelemetryClient 都出现 "not configured",但是我的 Instrumentation 密钥正确写入 ApplicationInsights.config
还有一件事是,当我像这样更改代码时:
var client = new TelemetryClient();
client.Context.InstrumentationKey = "The Key";
client.TrackEvent("TestEvent");
自定义事件出现在 Azure 门户中。但其他数据如请求、异常、依赖项不会自动记录在门户中。
我的申请有什么问题?
听起来您正在记录遥测数据,您可以控制 TelemetryClient - 就像上面的代码示例一样。
考虑到这一点,您需要检查以下几点:
- applicationinsights.config 已使用您的检测密钥进行配置。
- applicationinsights.config 正在部署到 WebApps
- 所有必要的遥测模块都在您的web.config 中
由于您是在本地接收遥测数据,我想说这就像您不部署 applicationinsights.config 文件一样简单。
在azure支持工程师的帮助下,问题已经解决
原因是在azure portal的App Setting中,有一个config sets "MOBILESERVICESDOTNET_EXTENSION_VERSION" = 1.0.478
删除此配置后,一切正常
但我仍然不确定其根本原因。为什么这个配置会造成这么多麻烦?