I am trying to use MiniProfiler for the ASP.NET MVC application. I installed the following NuGet packages. I configured the MiniProfiler in both Global.ascx and Also the script in my _Layout. But I am getting post script error for getting results. The loads without issue. But I don't get the results and no Icon on browser because there is no result to display due to POST error.
1- MiniProfiler.MVC5 2- MiniProfiler.EF6
Web.Config:
Global.ascx - application start:
In the current implementation, you'll accumulate MiniProfilers that never end, likely resulting in a memory leak (I'm noting this in case you're investigating those symptoms). It's a quick fix though!
If you check out the MiniProfiler MVC5 sample project here: Samples.Mvc5/Global.asax, the important difference is where the profiler is stopped. Ultimately, you want the
Application_EndRequest
(magically named) method to stop a per-request profiler, rather than the currentApplication_End
which will only shut down the current profiler (...which is likelynull
) when the application finally ends overall.