Upgraded DisposableTimer to wrap the profiler... now we should really just use DisposableTimer for all profiling.

This commit is contained in:
Shannon Deminick
2013-05-13 21:11:03 -10:00
parent b6f52bf782
commit 5890fe1849
10 changed files with 196 additions and 99 deletions

View File

@@ -99,6 +99,17 @@ namespace Umbraco.Web
UmbracoContext.EnsureContext(new HttpContextWrapper(UmbracoApplication.Context), ApplicationContext);
}
/// <summary>
/// Ensure the current profiler is the web profiler
/// </summary>
protected override void InitializeProfilerResolver()
{
base.InitializeProfilerResolver();
//Set the profiler to be the web profiler
ProfilerResolver.Current.SetProfiler(new WebProfiler());
}
/// <summary>
/// Adds custom types to the ApplicationEventsResolver
/// </summary>
@@ -240,9 +251,6 @@ namespace Umbraco.Web
{
base.InitializeResolvers();
//Set the profiler to be the web profiler
ProfilerResolver.Current.SetProfiler(new WebProfiler());
//set the default RenderMvcController
DefaultRenderMvcControllerResolver.Current = new DefaultRenderMvcControllerResolver(typeof(RenderMvcController));