How to configure mvc mini profiler with Linq to SQL?

江枫思渺然 提交于 2019-11-29 11:05:15

This used to happen if you had a ProfiledDbConnection in play and the actual profiler was set to null.

In general we avoid serving our internal consumers a ProfiledDbConnection if the current request is not profiled ... this means everything is just a bit faster.

Unfortunately, this can be sometimes tricky to do with EF and L2S. To overcome this I just checked in a change that allows you to use the Profiling bespoke objects even if no profiler is in play.

Nonetheless, my recommendation remains that you should be using raw connections where possible when you are not profiling.

Looks like this issue has finally been fixed in the latest commit:

https://github.com/SamSaffron/MiniProfiler/commit/bcea578dd47d7f9ccf1f495cf67c360cdece5f2a

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!