public DataProcessor( IDiskWorker diskWorker, ILog log, IShutdownManager shutdownManager, string diskPath, int warningSizeInGigabytes, int maxSizeInGigabytes) : base((int)TimeSpan.FromMinutes(90).TotalMilliseconds, log) { _diskWorker = diskWorker; _log = log; _diskPath = diskPath; _warningSizeInGigabytes = warningSizeInGigabytes > 0 ? warningSizeInGigabytes : 0; _maxSizeInGigabytes = maxSizeInGigabytes > 0 ? maxSizeInGigabytes : 0; shutdownManager.Register(this, 3); if (!Directory.Exists(_diskPath)) { Directory.CreateDirectory(_diskPath); } _dirInfo = new DirectoryInfo(_diskPath); Directory.SetCurrentDirectory(_diskPath); }
public DiskWorker( ILog log, IShutdownManager shutdownManager) : base((int)TimeSpan.FromSeconds(3).TotalMilliseconds, log) { _log = log; shutdownManager.Register(this, 1); }
public DiskWorker( ILog log, IShutdownManager shutdownManager, bool isHourlyBatched) : base((int)TimeSpan.FromSeconds(3).TotalMilliseconds, log) { _log = log; _isHourlyBatched = isHourlyBatched; shutdownManager.Register(this, 1); }
public RabbitMessageSubscriber( ILog log, IConsole console, IDataProcessor dataProcessor, IShutdownManager shutdownManager, string connectionString, string exchangeName) { _log = log; _console = console; _dataProcessor = dataProcessor; _connectionString = connectionString; _exchangeName = exchangeName; shutdownManager.Register(this, 0); }