本文介绍了在Application Insights中,Functions 2.0不会自动跟踪跨函数调用的依赖关系的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

借助Functions 2.0,它与Application Insights进行了更多集成,以跟踪依赖关系,并且我看到它正在跟踪对诸如存储帐户或服务总线之类的资源的调用.但是,当请求另一个2.0函数时,该请求 是可见的,但在原始请求下未跟踪其依赖项.而是在Application Insights中跟踪新请求,并在该函数下跟踪该第二个功能中的任何依赖项.

With Functions 2.0 it has more integration with Application Insights to track dependencies and I can see that it is tracking calls to resources such as storage accounts or service buses. However, when a request is made to another 2.0 function that request is visible, but its dependencies are not tracked under the original request. Instead a new request is tracked in Application Insights and any dependencies in that second function are tracked under that.

如果我们可以跨函数调用跟踪原始请求的完整路径,那将很有用,那么该功能是否可以通过其他方式计划或实现?

It would be useful if we could track the full path of the original request across function calls so is that feature planned or achievable another way?

我们已经研究过创建一个新的Activity并从Request-Id标头值设置其parentId,并正确填充了Application Insights中的时间轴,但是这导致了对函数调用的重复请求,并且产生了以下开销 需要在我们的功能代码中手动实现.

We have looked into creating a new Activity and setting its parentId from the Request-Id header value and that correctly populates the timeline in Application Insights, but this results in a duplicate request for the function call and has the overhead of needing to implement this manually in our function code.

推荐答案


这篇关于在Application Insights中,Functions 2.0不会自动跟踪跨函数调用的依赖关系的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-21 03:04