protected void Application_Start() { AreaRegistration.RegisterAllAreas(); WebApiConfig.Register(GlobalConfiguration.Configuration); FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); //MongoDBRepository.RegisterMongoDBContext(new PassportDBContext()); MongoRepositoryManager.Instance.RegisterMongoDBContext(); Initialize(); DLogger.SetLocalPath(@"c:\log\itrip\passport"); }
protected void Application_Start() { AreaRegistration.RegisterAllAreas(); WebApiConfig.Register(GlobalConfiguration.Configuration); FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); //MongoDBRepository.RegisterMongoDBContext(new iTripModelContext()); //MongoDBRepository.RegisterMongoIndex(); //MongoEntity.RemoveAll<Nationality>(); //MongoEntity.RemoveAll<NativePlace>(); //var initializer = new Initializer(); //var nations = initializer.InitializeNationality(); //MongoEntity.InsertBatch<NativePlace>(initializer.InitializeNativePlace(nations[0])); //MongoEntity.InsertBatch<Nationality>(nations); Initialize(); DLogger.SetLocalPath(@"c:\log\itrip\web"); }