コード例 #1
0
 public EventBusRabbitMQ(IFactoryRabbitMQ factory, IEventBusManager eventBusManager, ILogger <EventBusRabbitMQ> log)
 {
     _factory         = factory;
     _eventBusManager = eventBusManager;
     _eventBusManager.OnRemoveEventHandler += OnRemoveEvent;
     _log       = log;
     connection = _factory.CreateConnection();
     channel    = connection.CreateModel();
 }
コード例 #2
0
ファイル: EventBusRabbitMQ.cs プロジェクト: Hansdas/Blog_New
 public EventBusRabbitMQ(IFactoryRabbitMQ factory, IEventBusManager eventBusManager, ILogger <EventBusRabbitMQ> log)
 {
     _factory         = factory;
     _eventBusManager = eventBusManager;
     _eventBusManager.OnRemoveEventHandler += OnRemoveEvent;
     _log       = log;
     connection = _factory.CreateConnection();
     channel    = connection.CreateModel();
     channel.ExchangeDeclare(exchangeName, exchangeType);
     queueName = InitializeEventConsumer(queueName);
 }