Original code in messaging is refactored so that single entry method
publish can be called to publish message via different backend messaging
brokers according to configuration in freshmaker's config file.
Message body will contains complete event and associated builds information, each of them also contains URL that could be used to link back to freshmaker for another API call.
With this patch, a message can be sent in following ways
for fedmsg, publish('images.ready', {}) will send message to topic freshmaker.images.ready.
for rhmsg, publish('images.ready', {}) will send message to topic VirtualTopic.eng.freshmaker.images.ready
Original code in messaging is refactored so that single entry method
publish can be called to publish message via different backend messaging
brokers according to configuration in freshmaker's config file.
Message body will contains complete event and associated builds information, each of them also contains URL that could be used to link back to freshmaker for another API call.
With this patch, a message can be sent in following ways
publish('images.ready', {})will send message to topicfreshmaker.images.ready.publish('images.ready', {})will send message to topicVirtualTopic.eng.freshmaker.images.ready