How to Use Tracing in ASP.NET Web API

When debugging an ASP.NET application, you need to find out how the code is being executed and track its execution sequence. This is where tracing can help you. Using tracing, you can trace the flow of execution and how various events are happening in your ASP.NET Web API.

You can use the default trace writer in the Web API or you can create your own. This article will discuss both approaches and how it can be used to your advantage.

ASP.NET Web API has its own default tracing that can be used by just enabling it.  You’ll be using the SystemDiagnosticsTraceWriter class as the trace writer. If you create your own, it will be a different approach.

Read the rest of tutorial in this post:

Leave a Reply

Your email address will not be published. Required fields are marked *