Implement consumption of messages into the queue