[rabbitmq-discuss] Federated queue and bindings

lepolac lepolac at gmail.com
Tue Apr 29 10:59:21 BST 2014


Hi,

I have configured queue federation between 2 brokers, but can't see messages
on my downstream broker.

Here is the configuration on the downstream :

eval 'rabbit_federation_status:status().'
[[{queue,<<"federated-queue.test">>},
  {upstream_queue,<<"federated-queue.test">>},
  {type,queue},
  {vhost,<<"/">>},
  {upstream,<<"my-upstream">>},
  {status,running},
  {local_connection,<<"<rabbit2 at host2.2.6041.1>">>},
  {uri,<<"amqp://host1:17580">>},
  {timestamp,{{2014,4,29},{5,22,42}}}]]
...done.
 
 
./rabbitmqctl list_policies
Listing policies ...
/       federate-me     exchanges       ^federated     
{"federation-upstream-set":"all"}       0
/       federate-queue  queues  ^federated-queue       
{"federation-upstream-set":"all"}       0
 
 
Listing bindings ...
        exchange        A       queue   A       []
        exchange        federated-queue.test    queue   federated-queue.test   
[]
myexchange      exchange        federated-queue.test    queue           []
...done.
 
Bindings on upstream host1 :


Listing bindings ...
        exchange        A       queue   A       []
        exchange        federated-queue.test    queue   federated-queue.test   
[]
myexchange      exchange        federated-queue.test    queue           []
...done.

I have a feeling this has to do with the way my publisher or consumer is
binding.
QUEUE_NAME being obviously federated-queue.test and EXCHANGE_NAME being
myexchange

Consumer :

channel.queueDeclare(QUEUE_NAME, true, false, false, null);
channel.exchangeDeclare(EXCHANGE_NAME, "direct", true);
channel.queueBind(QUEUE_NAME,EXCHANGE_NAME,"");

Publisher :

  channel.queueDeclare(QUEUE_NAME,true, false, false, null);
  channel.exchangeDeclare(EXCHANGE_NAME, "direct", true);
  channel.queueBind(QUEUE_NAME,EXCHANGE_NAME,"");
  ....
  channel.basicPublish(EXCHANGE_NAME,"",null, message.getBytes());

This works locally, I can publish/consume messages on the same broker, but
if I run a consumer on the downstream I can't see messages.

Could use some help here, thanks :)



--
View this message in context: http://rabbitmq.1065348.n5.nabble.com/Federated-queue-and-bindings-tp35186.html
Sent from the RabbitMQ mailing list archive at Nabble.com.


More information about the rabbitmq-discuss mailing list