Reputation: 283
I'm very new to RabbitMQ and I need to write a program that has Multi Producer and multi consumer with a single queue. Is this possible to do what I've shown in the image? I found lots of examples but they are all with single producer. Any producer send messages to any consumer.
Upvotes: 5
Views: 7906
Reputation: 12419
In short, the answer is absolutely you can have many producers that publish to a single queue. I would recommend that you create an exchange and have your producers send things into an exchange which then forwards to a queue. In your simple diagram an exchange is not strictly necessary but it makes your solution more extensible in the future.
Upvotes: 6