Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to get Azure service fabric performance metrics #114

Open
TestUser0811 opened this issue Oct 27, 2020 · 0 comments
Open

How to get Azure service fabric performance metrics #114

TestUser0811 opened this issue Oct 27, 2020 · 0 comments

Comments

@TestUser0811
Copy link

TestUser0811 commented Oct 27, 2020

Currently configured telemetry to Service Fabric service Service

     return new WebHostBuilder().UseHttpSys()
                        .ConfigureServices(
                            services => services
                                .AddSingleton<StatelessServiceContext>(serviceContext)
                                .AddSingleton<ServiceFabricAppContext>(new ServiceFabricAppContext(){
                                        NodeName = serviceContext.NodeContext.NodeName,
                                        ServiceHostIP=serviceContext.NodeContext.IPAddressOrFQDN,
                                        ServiceHostPort=FabricRuntime.GetActivationContext().GetEndpoints()[0].Port
                                } )
                                    .AddSingleton<ITelemetryInitializer>((serviceProvider) => 
    FabricTelemetryInitializerExtension.CreateFabricTelemetryInitializer(serviceContext))) // Azure Service Fabric Telemetry 
   Initializer
                        .UseContentRoot(Directory.GetCurrentDirectory())
                           .UseApplicationInsights()
                        .UseStartup<Startup>()
                        .UseEnvironment(environment)
                        .UseServiceFabricIntegration(listener, ServiceFabricIntegrationOptions.None)
                        .UseUrls(url)
                        .Build();

Below are additional packages added,

  <PackageReference Include="Microsoft.ApplicationInsights.ServiceFabric.Native" Version="2.1.1" /> 
   <PackageReference Include="Microsoft.ServiceFabric.Diagnostics.Internal" Version="4.1.417" />

Right now under AzureApplicationInsights => logs, only "requests" table having data where as other required tables especially "performanceCounters" is empty.

What needs to be done/configured, so that already wired Azure Application insights instance can record performance Counters details like CPU, memory etc of existing service fabric nodes, which are hosting .Net Core 2.1 Web Api application?

Sampling not enabled from Azure portal.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant