gpt4 book ai didi

azure - 跟踪表中的 iKey 是什么 - KQL [ Kusto 查询语言] - Application Insights - 还查询以下 KQL 查询的优化

转载 作者:行者123 更新时间:2023-12-02 08:18:31 25 4
gpt4 key购买 nike

当我运行 .NET Core 应用程序时,我遇到了大约 60 个异常 - 特定类型 - 合作伙伴中心异常。

我已经处理了这些异常,但现在我正在编写一些 KQL 查询,以便我可以提前知道是否出现任何问题。

我想编写 KQL 查询,该查询将来会捕获来自合作伙伴中心的异常,但不会捕获此类异常 - 那么如何过滤掉它们?

我的查询看起来像 -

 traces 
| where customDimensions.LogLevel == "Error"
| where operation_Name == "functionName"
| where iKey != "************"

我看到了这个 iKey - 它是什么?我需要知道如何编写所需的查询。

另外:无法找到客户的购买费用和“errorName”:“RelationshipDoesNotExist”---->这一切都来自消息和customDimensions字段

我可以提取此 errorName 并排除这些类型的异常吗?有办法做到吗?

目前我已经使用:

where message !contains_cs "Could not find purchase charge for customer"

但它的计算成本很高,因此需要寻找替代方案来优化查询。

最佳答案

iKey 对应于仪器 key :

When you set up Application Insights monitoring for your web app, you create an Application Insights resource in Microsoft Azure. You open this resource in the Azure portal in order to see and analyze the telemetry collected from your app. The resource is identified by an instrumentation key (ikey). When you install the Application Insights package to monitor your app, you configure it with the instrumentation key, so that it knows where to send the telemetry.

( source )

I want to write KQL query which in future catches exceptions from partner center but not that type of exception - so how to filter them out?

异常存储在exceptions 表中。您可以根据已知属性(例如异常类型)过滤它们。例如,假设您想要除 NullReferenceException 类型之外的所有异常,您可以执行以下操作:

exceptions
| where ['type'] != "System.NullReferenceException"

关于azure - 跟踪表中的 iKey 是什么 - KQL [ Kusto 查询语言] - Application Insights - 还查询以下 KQL 查询的优化,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/70895191/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com