public void SetUp()
        {
            _container = SupportContainer.Reset();

            var configs = new Dictionary <String, ConfigurationDBRef>();

            var config = new ConfigurationDBRef();

            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative);
            configs["name1"] = config;

            config = new ConfigurationDBRef();
            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative, new Properties());
            //config.SetDataSourceConnection("context", new Properties());
            config.LRUCache  = 10000;
            configs["name2"] = config;

            config = new ConfigurationDBRef();
            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative, new Properties());
            config.SetExpiryTimeCache(1, 3);
            configs["name3"] = config;

            SchedulingService schedulingService = new SchedulingServiceImpl(
                new TimeSourceServiceImpl(), _container.Resolve <ILockManager>());

            _databaseServiceImpl = new DatabaseConfigServiceImpl(
                configs, schedulingService, new ScheduleBucket(1),
                SupportEngineImportServiceFactory.Make(_container));
        }
Example #2
0
        public void SetUp()
        {
            IDictionary <String, ConfigurationDBRef> configs = new Dictionary <String, ConfigurationDBRef>();

            ConfigurationDBRef config = new ConfigurationDBRef();

            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative);
            configs["name1"] = config;

            config = new ConfigurationDBRef();
            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative, new Properties());
            //config.SetDataSourceConnection("context", new Properties());
            config.LRUCache  = 10000;
            configs["name2"] = config;

            config = new ConfigurationDBRef();
            config.SetDatabaseDriver(SupportDatabaseService.DbDriverFactoryNative, new Properties());
            config.SetExpiryTimeCache(1, 3);
            configs["name3"] = config;

            SchedulingService schedulingService = new SchedulingServiceImpl(new TimeSourceServiceImpl());

            _databaseServiceImpl = new DatabaseConfigServiceImpl(configs, schedulingService, new ScheduleBucket(1));
        }