[rabbitmq-discuss] Dynamic queue problem

Francesco Mazzoli francesco at rabbitmq.com
Tue Sep 11 16:04:23 BST 2012


At Tue, 11 Sep 2012 00:57:00 +0530,
Bhaskar teja wrote:
> 
> Thank you,
> 
> Please let me know if the following design pattern is good enough,
> 
> Producer:
>   Exchange name - "event-notifications"
>   Type - topic
>   Routing key - "mail.mobile.web.documents"
> 
> Consumer  for web notifications:
>   Exchange name - "event-notifications"
>   Type - topic
>   Routing key - "#.web.documents"
>   Queue name - "web_notifications"
> 
> Consumer  for mobile notifications:
>   Exchange name - "event-notifications"
>   Type - topic
>   Routing key - "#.mobile.#.documents"
>   Queue name - "mobile_notifications"
> 
> Consumer  for mail notifications:
>   Exchange name - "event-notifications"
>   Type - topic
>   Routing key - "mail.#.documents"
>   Queue name - "mail_notifications"
> 

That will work, but you don't need the hashes if your topic is always going to
be of the form `*.*.*.*'.

--
Francesco * Often in error, never in doubt


More information about the rabbitmq-discuss mailing list