microsoft / ApplicationInsights-ServiceFabric

ApplicationInsights SDK for ServiceFabric projects
MIT License
63 stars 26 forks source link

How to integrate AI to Guest exe Service Fabric? #57

Closed ifle closed 6 years ago

ifle commented 6 years ago

How to integrate AI to Guest Executable Service Fabric? I'm not found any sample how to do that.

Thanks

brahmnes commented 6 years ago

For Guest Executable, there aren't much other than just including the Microsoft.ApplicationInsights.ServiceFabric nuget into the project that built the guest exe. You cannot include Microsoft.ApplicationInsights.ServiceFabric.Native because this nuget has references to the Service Fabric runtime and presumably your guest exe doesn't reference the Service Fabric runtime.

After that, you can include the FabricTelemetryInitializer in your AI config, which will pick up the properties from environment variables when you call the Track methods on TelemetryClient.

ifle commented 6 years ago

The guest exe is C++ server. That is strange that there are not any way send the basic telemetry like CPU, Memory to AI.

brahmnes commented 6 years ago

If you want machine wide performance counters sent to AI, the best option is to use Windows Azure Diagnostics, commonly what we call the WAD agent.

This document describes that with info on how to set it up https://docs.microsoft.com/en-us/azure/service-fabric/service-fabric-diagnostics-overview

brahmnes commented 6 years ago

@ifle, I am closing this issue assuming the question is answer. If not, please reactivate.