Exemplo n.º 1
0
        public void Initialize(ConfigSettings settings)
        {
            AquilesHelper.Initialize();
            _storage = new InventoryStorage(settings.InventoryCluster);

            _delayedMutationMgr = new DelayedMutationManager();
            _delayedMutationMgr.Start();
            _storage.DelayedMutationMgr = _delayedMutationMgr;

            if (settings.InventoryMigrationActive)
            {
                _legacyStorage = new LegacyMysqlInventoryStorage(settings.LegacyInventorySource);
            }

            _storageSelector = new CassandraMigrationProviderSelector(settings.InventoryMigrationActive, settings.CoreConnectionString,
                                                                      _storage, _legacyStorage);

            ProviderRegistry.Instance.RegisterInterface <IInventoryProviderSelector>(_storageSelector);
        }
Exemplo n.º 2
0
        public void Initialize(ConfigSettings settings)
        {
            AquilesHelper.Initialize();
            _storage = new InventoryStorage(settings.InventoryCluster);

            _delayedMutationMgr = new DelayedMutationManager();
            _delayedMutationMgr.Start();
            _storage.DelayedMutationMgr = _delayedMutationMgr;

            if (settings.InventoryMigrationActive)
            {
                _legacyStorage = new LegacyMysqlInventoryStorage(settings.LegacyInventorySource);
            }

            _storageSelector = new CassandraMigrationProviderSelector(settings.InventoryMigrationActive, settings.CoreConnectionString,
                _storage, _legacyStorage);

            ProviderRegistry.Instance.RegisterInterface<IInventoryProviderSelector>(_storageSelector);
        }