Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Helper class to configure Application Insights and our Telemetry Processor
using System.Configuration;
using Microsoft.ApplicationInsights.Extensibility;
namespace Samples.App_Start
{
public static class AppInsightsConfig
{
public static void RegisterAppInsights()
{
TelemetryConfiguration.Active.InstrumentationKey =
System.Web.Configuration.WebConfigurationManager.AppSettings["ApplicationInsightsKey"];
var builder = TelemetryConfiguration.Active.TelemetryProcessorChainBuilder;
builder.Use(next => new My404Filter(next));
builder.Build();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.