In our company, we built a push service in Go and we put it on four machines to make sure transmission speed, when we need send notifications we send message to rabbitMQ, then push service will get the messages from queue, but sometimes we find there is only one machines get the message.
Here is the config of rabbitMQ consumers:
msgs, err := ch.Consume(
q.Name, // queue
consumerTag, // consumer
true, // auto-ack
false, // exclusive
false, // no-local
false, // no-wait
nil, // args
)
How should I set the config to make sure each consumer get the same quantity of messages?