Q:

Rabbitmq and multiple subscribers

Is it possible for a queue to have multiple consumers? 
I am working on a system where a single queue needs to be accessed by multiple consumers for different micro-services.   Is it possible for the queue to retain data until after a consumer has consumed it or are there other possible methods for multiple consumers to consume data from a queue? 

A:

A queue should (except for specific cases) be treated as an inbox for each application, so each consumer interested on some message type should have its own queue.  
Don't forget that AMQP promotes a producer/consumer pattern, so each app would "steal" a message to other, this is very nice when  the consumers are many replicas of the same microservices, while if different microservices are interested in same messages they have to declare that want message copies on thier queues creating a binding.  The binding is a rule that implements the following behaviour
given the exchange < E >
when a message is sent on < E > with routing key < k >
then put a copy on the queue < Q >
So the queue is just a buffer, the routing key resembles the content of the message
when the messages are put on the queue, the consumer receives is and executes some business logic.  If the logic has been correctly executed, the service doesn't need the message anymore.  If an error occours, you have to decide if there is need to retry the execution (hopefully with a different healthy replica) or give up and save the message for further post-mortem troubleshooting.  This is accomplished with ack/nack packets (and the dead letter exchange) that the consumer sends to the broker.  Most of AMQP libraries do the job automagically: Spring AMQP sends a nack if an exception has been thrown through the message listener associated to the queue

