Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Binding queue using existing cosumerChannel #1716

Merged
merged 1 commit into from
Jul 7, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions src/BuildingBlocks/EventBus/EventBusRabbitMQ/EventBusRabbitMQ.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,13 +143,10 @@ private void DoInternalSubscription(string eventName)
{
_persistentConnection.TryConnect();
}

using (var channel = _persistentConnection.CreateModel())
{
channel.QueueBind(queue: _queueName,
exchange: BROKER_NAME,
routingKey: eventName);
}

_consumerChannel.QueueBind(queue: _queueName,
exchange: BROKER_NAME,
routingKey: eventName);
}
}

Expand Down