[英]How do I configure a .NET Core 2.1 service fabric service to automatically use request and dependency tracking in application insights
I've created a Service Fabric .NET Core 2.2 (NOT ASP.NET Core) stateless service using the V2 remote listener. 我使用V2远程监听器创建了Service Fabric .NET Core 2.2(非ASP.NET核心)无状态服务。 How do I configure Application Insighjts to automatically perform request and dependency tracking. 如何配置Application Insighjts以自动执行请求和依赖关系跟踪。 All the examples I can find show how to do this for ASP.NET Core via the ConfigureService method when setting up the http service listener but NOT how to do this when usiong the RPC V2 remote listener. 我可以找到的所有示例都说明了在设置http服务侦听器时如何通过ConfigureService方法为ASP.NET Core执行此操作,但在使用RPC V2远程侦听器时却不知道如何执行此操作。
I've tried using TelemetryConfiguration and TelemetryClient to set this up (I'm aware that I can manually start Request and Dependency activities) but can't get the service to log dependency calls to other Azure resources ie service bus. 我已经尝试使用TelemetryConfiguration和TelemetryClient来设置它(我知道我可以手动启动Request和Dependency活动)但是无法获得服务来记录对其他Azure资源(即服务总线)的依赖性调用。
I also have another service fabric service with an http listener and have set that up via ConfigureService an it works great. 我还有另一个带有http监听器的服务结构服务,并通过ConfigureService进行设置,它运行良好。 I'd like my remote listener service to also track requests and dependencies. 我希望我的远程侦听器服务也跟踪请求和依赖项。 How do I configure the service to do this? 如何配置服务来执行此操作?
ApplicationInsights SDK by default only captures Http requests and dependencies. 默认情况下,ApplicationInsights SDK仅捕获Http请求和依赖项。 If using remoting, then see this repo on how to capture Requests and Dependencies. 如果使用远程处理,请参阅此repo,了解如何捕获请求和依赖关系。 https://github.com/Microsoft/ApplicationInsights-ServiceFabric https://github.com/Microsoft/ApplicationInsights-ServiceFabric
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.