Esempio n. 1
0
        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();
        }
Esempio n. 2
0
        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();
        }