jsk*_*jsk 5 logging azure-application-insights asp.net-core asp.net-core-2.0
我在某处读到 Application Insights 应该使用结构化日志,并且我正在尝试使用 ILogger 的 BeginScope 将数据记录到 Application Insights:
using (_logger.BeginScope("Some really useful information"))
{
// something something
_logger.LogError("Oh no.");
}
Run Code Online (Sandbox Code Playgroud)
但是,在检查 Application Insights 中的跟踪时,我没有从 BeginScope 获取日志数据,在本例中只是“哦,不”。这是一个 .NET Core 2.0 应用程序。Application Insights ILogger 的默认实现是否不支持 BeginScope?或者我错过了什么?
| 归档时间: |
|
| 查看次数: |
4829 次 |
| 最近记录: |