Skip to content

Instantly share code, notes, and snippets.

@hd9
Last active February 19, 2020 16:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hd9/29e9ab01a048edd04511d926b05d2258 to your computer and use it in GitHub Desktop.
Save hd9/29e9ab01a048edd04511d926b05d2258 to your computer and use it in GitHub Desktop.
Suppressing Application Insights telemetry on an ASP.NET Core web applications
// **********************************************
// Fore more information, visit:
// https://blog.hildenco.com/2020/02/suppressing-application-insights.html
// **********************************************
// To register your custom telemetry processor, update the
// ConfigureServices on your Startup.cs class adding your custom
/// telemetry processor. Ex: SuppressFaviconFilter
public void ConfigureServices(IServiceCollection services)
{
services.AddApplicationInsightsTelemetry();
services.AddApplicationInsightsTelemetryProcessor<SuppressFaviconFilter>();
services.AddControllersWithViews();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment