问题
I want to add analytics to my Windows Phone 8 app and that's all fine except I now want to trace when my background agent triggers a specific event.
Does App Insights support this?
回答1:
I'd like to say that Application Insights does support the scenario you are describing. Recent versions of the Application Insights should support background tasks. However, you should use the "core" package, and not the full platform package.
This core package provides all the APIs needed to send telemetry to AppInsights. It doesn't provide any of the automatic context or telemetry collection, and hence doesn't have any dependencies (for example on the dispatcher) which allows it to work on a background task.
We would love to hear more about how this scenario is working out for you.
来源:https://stackoverflow.com/questions/25852654/can-i-use-app-insights-in-a-background-agent