public DataBusIncomingStep(IDataBusStorage dataBusStorage) { if (dataBusStorage == null) { throw new ArgumentNullException(nameof(dataBusStorage)); } _dataBusStorage = dataBusStorage; }
public DefaultDataBus(IDataBusStorage dataBusStorage) { if (dataBusStorage == null) { throw new ArgumentNullException(nameof(dataBusStorage)); } _dataBusStorage = dataBusStorage; }
/// <summary> /// Creates the decorator, wrapping the given <paramref name="innerDataBusStorage"/> /// </summary> public ZippingDataBusStorageDecorator(IDataBusStorage innerDataBusStorage, DataCompressionMode dataCompressionMode) { if (innerDataBusStorage == null) { throw new ArgumentNullException(nameof(innerDataBusStorage)); } _innerDataBusStorage = innerDataBusStorage; _dataCompressionMode = dataCompressionMode; }
/// <summary> /// Establishes a fake presence of a configured data bus, using the given <see cref="InMemDataStore"/> to retrieve data /// </summary> public static IDisposable EstablishContext(InMemDataStore dataStore) { if (dataStore == null) throw new ArgumentNullException(nameof(dataStore)); TestDataBusStorage = new InMemDataBusStorage(dataStore); return new CleanUp(() => { TestDataBusStorage = null; }); }
/// <summary> /// Establishes a fake presence of a configured data bus, using the given <see cref="InMemDataStore"/> to retrieve data /// </summary> public static IDisposable EstablishContext(InMemDataStore dataStore) { if (dataStore == null) { throw new ArgumentNullException(nameof(dataStore)); } TestDataBusStorage = new InMemDataBusStorage(dataStore); return(new CleanUp(() => { TestDataBusStorage = null; })); }
/// <summary> /// Creates the fake data bus, optionally using the given in-mem data store to store attachments /// </summary> public FakeDataBus(IRebusTime rebusTime) { // if there is an "ambient" storage, use that if (TestBackdoor.TestDataBusStorage != null) { _dataBusStorage = TestBackdoor.TestDataBusStorage; } // last resort: just fake it in mem else { _inMemDataStore = new InMemDataStore(); _dataBusStorage = new InMemDataBusStorage(_inMemDataStore, rebusTime); } }
/// <summary> /// Creates the fake data bus, optionally using the given in-mem data store to store attachments /// </summary> /// <param name="dataStore"></param> public FakeDataBus(InMemDataStore dataStore = null) { // if a data store was passed in, we use that if (dataStore != null) { _dataBusStorage = new InMemDataBusStorage(dataStore); } // otherwise, if there is an "ambient" storage, use that else if (TestDataBusStorage != null) { _dataBusStorage = TestDataBusStorage; } // last resort: just fake it in mem else { _dataBusStorage = new InMemDataBusStorage(new InMemDataStore()); } }
protected override void SetUp() { _factory = new TDataStorageFactory(); _storage = _factory.Create(); }
public DataBusIncomingStep(IDataBusStorage dataBusStorage) { _dataBusStorage = dataBusStorage; }
public DataBusIncomingStep(IDataBusStorage dataBusStorage) { _dataBusStorage = dataBusStorage ?? throw new ArgumentNullException(nameof(dataBusStorage)); }
protected override void SetUp() { _factory = new SqlServerDataBusStorageFactory(); _storage = _factory.Create(); }
protected override void SetUp() { _factory = new AmazonS3DataBusStorageFactory(); _storage = _factory.Create(); }
public DefaultDataBus(IDataBusStorage dataBusStorage) { _dataBusStorage = dataBusStorage ?? throw new ArgumentNullException(nameof(dataBusStorage)); }
public static void EnableTestMode(IDataBusStorage dataBusStorage) { TestDataBusStorage = dataBusStorage; }
protected override void SetUp() { _factory = new TDataStorageFactory(); _storage = _factory.Create(); _management = _storage as IDataBusStorageManagement; }
/// <summary> /// Creates the decorator, wrapping the given <paramref name="innerDataBusStorage"/> /// </summary> public ZippingDataBusStorageDecorator(IDataBusStorage innerDataBusStorage, DataCompressionMode dataCompressionMode) { if (innerDataBusStorage == null) throw new ArgumentNullException(nameof(innerDataBusStorage)); _innerDataBusStorage = innerDataBusStorage; _dataCompressionMode = dataCompressionMode; }
public DefaultDataBus(IDataBusStorage dataBusStorage) { _dataBusStorage = dataBusStorage; }
public DefaultDataBus(IDataBusStorage dataBusStorage, IDataBusStorageManagement dataBusStorageManagement) { _dataBusStorage = dataBusStorage ?? throw new ArgumentNullException(nameof(dataBusStorage)); _dataBusStorageManagement = dataBusStorageManagement; }