Adding code for publish-subscribe pattern in rabbit mq