public DeadLetterReprocessorHost(GlobalOptions globals, DeadLetterReprocessorCliOptions cliOptions) : base(globals) { var deadLetterStore = new MongoDeadLetterStore(globals.MongoDatabases.DeadLetterStoreOptions, Globals.RabbitOptions.RabbitMqVirtualHost); _deadLetterQueueConsumer = new DeadLetterQueueConsumer(deadLetterStore, globals.DeadLetterReprocessorOptions); _deadLetterRepublisher = new DeadLetterRepublisher(deadLetterStore, RabbitMqAdapter.GetModel("DeadLetterRepublisher")); _cliOptions = cliOptions; }
public void TestWaitAfterChannelClosed() { IModel model = _testAdapter.GetModel("TestConnection"); model.ConfirmSelect(); _testAdapter.Shutdown(RabbitMqAdapter.DefaultOperationTimeout); Assert.True(model.IsClosed); Assert.Throws <AlreadyClosedException>(() => model.WaitForConfirms()); }