private static void Main() { //Start profiling ConsoleProfiling.Start(); using (StackExchange.Profiling.MiniProfiler.Current.Step("Call Methods")) { DoTheQuickWork(); DoTheSlowWork(); } //Stop profiling and show results Console.WriteLine(ConsoleProfiling.StopAndGetConsoleFriendlyOutputString()); //Allow viewing of results Console.WriteLine("... press 'Enter' to exit process ..."); Console.ReadLine(); }
private static void Main(string[] args) { //Configure building blocks ConfigureIocAndAop(); //Start profiling ConsoleProfiling.Start(); //Run the application var app = _container.Resolve <IConsoleApplication>(); app.Run(); //Stop profiling and show results Console.WriteLine(ConsoleProfiling.StopAndGetConsoleFriendlyOutputStringWithSqlTimings()); //Allow viewing of results Console.WriteLine("... press 'Enter' to exit process ..."); Console.ReadLine(); }