예제 #1
0
 protected void Application_Start()
 {
     NearbyConfig.RetrieveSecretsAsync(WebConfigurationManager.AppSettings["dumpling_ad_client_id"], WebConfigurationManager.AppSettings["thumbprint"]).Wait();
     AreaRegistration.RegisterAllAreas();
     GlobalConfiguration.Configure(WebApiConfig.Register);
     FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
     BundleConfig.RegisterBundles(BundleTable.Bundles);
 }
        public override bool OnStart()
        {
            // Before events or anything else can happen, we have to do this.
            NearbyConfig.RetrieveSecretsAsync(ConfigurationManager.AppSettings["dumpling_ad_client_id"], ConfigurationManager.AppSettings["thumbprint"]).Wait();
            DumplingEventHub.FireEvent(new DataWorkerStartEvent()).Wait();
            // Set the maximum number of concurrent connections
            ServicePointManager.DefaultConnectionLimit = 12;

            return(base.OnStart());
        }