1
votes

I am setting up Application Insights for a worker role, and the documentation states:

Add the Application Insights for Web NuGet package. This version of the SDK includes modules that add server context such as role information. For worker roles, use Application Insights for Windows Services.

I cannot find a a Windows Service version of the Nuget package.
Does anyone know what it is called (if it exists)?

2

2 Answers

0
votes

You would need these nuget packages:

Microsoft.ApplicationInsights

  Microsoft.ApplicationInsights.Agent.Intercept
  Microsoft.ApplicationInsights.DependencyCollector
  Microsoft.ApplicationInsights.PerfCounterCollector
  Microsoft.ApplicationInsights.TraceListener
  Microsoft.ApplicationInsights.Web
  Microsoft.ApplicationInsights.Web.TelemetryChannel

Here https://github.com/Microsoft/ApplicationInsights-Home/tree/master/Samples/AzureEmailService/WorkerRoleB you can find a sample of a project that is set up with documentation.

be sure to read the chapter: Report Dependencies

3
votes

You do not need Web. You need Windows Server (not service). Nuget package is here: https://www.nuget.org/packages/Microsoft.ApplicationInsights.WindowsServer/