Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What happened to HttpConfiguration.EnableSystemDiagnosticsTracing

I am using the new WebTools 2012.2, and the help files says to add config.EnableSystemDiagnosticsTracing to your Global.asax.

However, this method doesnt exist on HttpConfiguration.

like image 218
John Waters Avatar asked Apr 12 '13 17:04

John Waters


2 Answers

The EnableSystemDiagnosticsTracing extension is part of the Tracing package. Do you have the Microsoft.AspNet.WebApi.Tracing package installed?

Also make sure to have the using System.Web.Http; namespace.

like image 60
Kiran Avatar answered Dec 29 '22 01:12

Kiran


Documentation: link

To install use:

Install-Package Microsoft.AspNet.WebApi.Tracing Update-Package Microsoft.AspNet.WebApi.WebHost

After that check the following in your project:

  1. Add dll-file \packages\Microsoft.AspNet.WebApi.Tracing.5.2.2\lib\net45\System.Web.Http.Tracing.dll to your project.
  2. Add the following to WebApiConfig.cs using System.Web.Http; using System.Web.Http.Tracing;

And

//tracing config.EnableSystemDiagnosticsTracing();

like image 32
Christiaan Avatar answered Dec 29 '22 02:12

Christiaan