Announcement Announcement Module
No announcement yet.
RabbitMQ + Spring AMQP Configuration Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • RabbitMQ + Spring AMQP Configuration

    I'm currently using ActiveMQ and want to try out RabbitMQ; to that end I need some clarification on the following:
    • Can I use org.springframework.amqp.rabbit.listener.adapter.M essageListenerAdapter and org.springframework.amqp.rabbit.listener.SimpleMes sageListenerContainer, to listen for and handle messages like I do with org.springframework.jms.listener.adapter.MessageLi stenerAdapter and org.springframework.jms.listener.DefaultMessageLis tenerContainer?
    • The hello world example on github does not demonstrate how to create an exchange or how to bind a queue to it. Can anyone explain how to do so or point me to an example that does?

  • #2
    Yes, the listener container model is designed to look and feel as much like Spring Jms counterparts as possible.

    The hello-world sample only uses the default exchange and binding. The stocks sample uses explicit exchanges and bindings (e.g., and there are examples in the user guide ( The easiest thing is to declare bean definitions of the right type and a RabbitAdmin with autoStartup=true, and the namespace takes care of that if you use XML.
    Last edited by Dave Syer; Aug 15th, 2011, 03:38 AM. Reason: spelling