none
AI for console or windows services is not working.

    Question

  • Hi, I have created a basic console app with AI following the blog https://azure.microsoft.com/en... , however no metrics are captured in AI of my Azure account. There isn't any error/exception reported either. Am I missing anything here ? Below is the code.

    using System;
    using Microsoft.ApplicationInsights;
    namespace Logger
    {
    class Program
    {
    static void Main(string[] args)
    {
    TelemetryClient tc = new TelemetryClient();
    tc.Context.User.Id = Environment.UserName;
    tc.Context.Session.Id = Guid.NewGuid().ToString();
    tc.Context.Device.OperatingSystem = Environment.OSVersion.ToString();
    tc.TrackPageView("Form1");
    tc.Flush();
    System.Threading.Thread.Sleep(1000);
    }
    }
    }

    Application Insights file:

    <applicationinsights xmlns="http://schemas.microsoft.com/A...">
    <instrumentationkey>
    566f1acc-99d3-460e-9539-832ca2ba7a6a
    </instrumentationkey>
    <telemetrychannel type="Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel, Microsoft.AI.ServerTelemetryChannel"/>
    <telemetryprocessors>
    <add type="Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor, Microsoft.AI.ServerTelemetryChannel">
    <maxtelemetryitemspersecond>5</maxtelemetryitemspersecond>
    </add>
    </telemetryprocessors>
    <telemetryinitializers>
    <add type="Microsoft.ApplicationInsights.WindowsServer.AzureRoleEnvironmentTelemetryInitializer, Microsoft.AI.WindowsServer"/>
    <add type="Microsoft.ApplicationInsights.WindowsServer.DomainNameRoleInstanceTelemetryInitializer, Microsoft.AI.WindowsServer"/>
    <add type="Microsoft.ApplicationInsights.WindowsServer.BuildInfoConfigComponentVersionTelemetryInitializer, Microsoft.AI.WindowsServer"/>
    </telemetryinitializers>
    <telemetrymodules>
    <add type="Microsoft.ApplicationInsights.WindowsServer.DeveloperModeWithDebuggerAttachedTelemetryModule, Microsoft.AI.WindowsServer"/>
    <add type="Microsoft.ApplicationInsights.WindowsServer.UnhandledExceptionTelemetryModule, Microsoft.AI.WindowsServer"/>
    <add type="Microsoft.ApplicationInsights.WindowsServer.UnobservedExceptionTelemetryModule, Microsoft.AI.WindowsServer"/>
    </telemetrymodules>
    <severity>Verbose</severity>
    </applicationinsights>

    Monday, July 11, 2016 4:01 AM

Answers

All replies