コード例 #1
0
ファイル: HttpModule.cs プロジェクト: rytmis/Glimpse
        static HttpModule()
        {
            var serviceLocator = new AspNetServiceLocator();
            Factory = new Factory(serviceLocator);
            serviceLocator.Logger = Factory.InstantiateLogger();

            try
            {
                BuildManager.GetReferencedAssemblies();
                serviceLocator.Logger.Debug("Preloaded all referenced assemblies with System.Web.Compilation.BuildManager.GetReferencedAssemblies()");
            }
            catch (Exception exception)
            {
                serviceLocator.Logger.Error("Call to System.Web.Compilation.BuildManager.GetReferencedAssemblies() failed.", exception);
            }
        }
コード例 #2
0
ファイル: HttpModule.cs プロジェクト: GitObjects/Glimpse
        static HttpModule()
        {
            var serviceLocator = new AspNetServiceLocator();
            Factory = new Factory(serviceLocator);
            ILogger logger = Factory.InstantiateLogger();
            serviceLocator.Logger = logger;

            try
            {
                BuildManager.GetReferencedAssemblies();
                serviceLocator.Logger.Debug("Preloaded all referenced assemblies with System.Web.Compilation.BuildManager.GetReferencedAssemblies()");
            }
            catch (Exception exception)
            {
                serviceLocator.Logger.Error("Call to System.Web.Compilation.BuildManager.GetReferencedAssemblies() failed.", exception);
            }

            AppDomain.CurrentDomain.SetData(Constants.LoggerKey, logger);
            AppDomain.CurrentDomain.DomainUnload += (sender, e) => OnAppDomainUnload((AppDomain)sender);
        }
コード例 #3
0
ファイル: HttpModule.cs プロジェクト: rroman81/Glimpse
 static HttpModule()
 {
     var serviceLocator = new AspNetServiceLocator();
     Factory = new Factory(serviceLocator);
     serviceLocator.Logger = Factory.InstantiateLogger();
 }