public TradesMigrationService( ICandlesHistoryRepository candlesHistoryRepository, TradesMigrationHealthService tradesMigrationHealthService, ILogFactory logFactory, IHealthNotifier healthNotifier, string sqlConnString, int sqlQueryBatchSize, TimeSpan sqlTimeout, int candlesPersistenceQueueMaxSize ) { _candlesHistoryRepository = candlesHistoryRepository ?? throw new ArgumentNullException(nameof(candlesHistoryRepository)); _tradesMigrationHealthService = tradesMigrationHealthService ?? throw new ArgumentNullException(nameof(tradesMigrationHealthService)); _logFactory = logFactory; _healthNotifier = healthNotifier; if (logFactory == null) { throw new ArgumentNullException(nameof(logFactory)); } _log = logFactory.CreateLog(this); _sqlConnString = sqlConnString; _sqlQueryBatchSize = sqlQueryBatchSize; _sqlTimeout = sqlTimeout; _candlesPersistenceQueueMaxSize = Convert.ToInt32(candlesPersistenceQueueMaxSize * 1.1); // Safe reserve }
public TradesMigrationManager( IAssetPairsManager assetPairsManager, ITradesMigrationService tradesMigrationServicey, TradesMigrationHealthService tradesMigrationHealthService, ILog log, int sqlQueryBatchSize, bool migrationEnabled ) { _assetPairsManager = assetPairsManager ?? throw new ArgumentNullException(nameof(assetPairsManager)); _tradesMigrationService = tradesMigrationServicey ?? throw new ArgumentNullException(nameof(tradesMigrationServicey)); _tradesMigrationHealthService = tradesMigrationHealthService ?? throw new ArgumentNullException(nameof(tradesMigrationHealthService)); _log = log ?? throw new ArgumentNullException(nameof(log)); _sqlQueryBatchSize = sqlQueryBatchSize; MigrationEnabled = migrationEnabled; }
public TradesMigrationService( ICandlesHistoryRepository candlesHistoryRepository, TradesMigrationHealthService tradesMigrationHealthService, ILog log, string sqlConnString, int sqlQueryBatchSize, TimeSpan sqlTimeout, int candlesPersistenceQueueMaxSize ) { _candlesHistoryRepository = candlesHistoryRepository ?? throw new ArgumentNullException(nameof(candlesHistoryRepository)); _tradesMigrationHealthService = tradesMigrationHealthService ?? throw new ArgumentNullException(nameof(tradesMigrationHealthService)); _log = log ?? throw new ArgumentNullException(nameof(log)); _sqlConnString = sqlConnString; _sqlQueryBatchSize = sqlQueryBatchSize; _sqlTimeout = sqlTimeout; _candlesPersistenceQueueMaxSize = Convert.ToInt32(candlesPersistenceQueueMaxSize * 1.1); // Safe reserve }
public TradesMigrationManager( IAssetPairsManager assetPairsManager, ITradesMigrationService tradesMigrationServicey, TradesMigrationHealthService tradesMigrationHealthService, ILogFactory logFactory, int sqlQueryBatchSize, bool migrationEnabled ) { _assetPairsManager = assetPairsManager ?? throw new ArgumentNullException(nameof(assetPairsManager)); _tradesMigrationService = tradesMigrationServicey ?? throw new ArgumentNullException(nameof(tradesMigrationServicey)); _tradesMigrationHealthService = tradesMigrationHealthService ?? throw new ArgumentNullException(nameof(tradesMigrationHealthService)); if (logFactory == null) { throw new ArgumentNullException(nameof(logFactory)); } _log = logFactory.CreateLog(this); _sqlQueryBatchSize = sqlQueryBatchSize; MigrationEnabled = migrationEnabled; }