4.Write a method to populate messages in the queue:
rabbitmq plugin injects a rabbitSend() method in all the services and controllers

//This method could be defined in any service.
populateQueue(){
rabbitSend('myTestQueue', "some id:1,some action: do this")
// Message has to be a String
}

5.Write a handler Service which shall handle the messages that are put in the queue:

class QueueBasedMyTestService {
static rabbitQueue = 'myTestQueue'
def solrSearchService
// This method gets called by the plugin whenever there is any new message in the queue.
// We can configure n number of parallel handlers
void handleMessage(message){
log.info("Message Received ${message}")
// We have recieved the message from the rabbitmq server's queue
}
}