Rabbitmq Basic Publish
Solution 1:
This error is caused by the fact that you are attempting to re-declare a queue with different parameters.
As the documentation states, a queue declaration is intended to be an idempotent assertion - if the queue does not exist, it is created. If it does exist, but has different parameters, you get this error.
Declaration and Property Equivalence
Before a queue can be used it has to be declared. Declaring a queue will cause it to be created if it does not already exist. The declaration will have no effect if the queue does already exist and its attributes are the same as those in the declaration. When the existing queue attributes are not the same as those in the declaration a channel-level exception with code 406 (PRECONDITION_FAILED) will be raised.
Something is going on in your DeclareQueue("hound");
method that is different from channel.queue_declare(queue='hound')
. Since we don't have the code for that, it is impossible to explain further, but I think this is sufficient information for you to solve the problem.
Post a Comment for "Rabbitmq Basic Publish"