Closed jackcarrozzo closed 9 years ago
It looks like you have a really old version of Qpid. The latest is 0.32 https://qpid.apache.org/download.html. I tested on a recent version of Qpid a while ago, and it seemed to work fine. I'll try again on the latest version tonight, as well as your version if I can get a hold of it.
I think you may be using the packaged version on Ubuntu or something. http://packages.ubuntu.com/vivid/qpidd
The way the protocol works is that it negotiates a frame size when connecting. Both the server and client must support a minimum frame size, and my library adheres to that specification. The version of Qpid that you have may not be respecting the AMQP 0.9.1 spec.
I'll take a look again tonight, since I use this library in production so I want to make sure there's no bugs whatsoever. In the meantime, in the amqpy.Connection()
constructor, try passing in a larger value for frame_max=131072
, which is the default. Try making it 1-10MB, but that's an extremely large frame size and shouldn't be required. The server breaks up payloads into multiple frames automatically anyway. In addition, set the python standard logger for "amqpy" to the logging.DEBUG
level, and you'll see a lot of useful log messages related to what's going on with the connection.
It could also be that there's something wrong with the Qpid configuration.
You could also try using RabbitMQ to check if everything else is ok first: http://packages.ubuntu.com/vivid/rabbitmq-server. I'm using RabbitMQ in production with this library successfully.
http://amqpy.readthedocs.org/en/latest/
Apache Qpid is confirmed to work, but only with “anonymous” authentication.
Try setting the authentication settings appropriately. This could be due to the server trying to negotiate an unsupported auth mechanism.
Built latest qpidd (qpidd (qpid-cpp) version 0.32
) from source; started with --auth=no
which, while not specifically mentioning "anonymous" authentication, does imply that it disables connection auth. Same thing.
Making the frame_size
much larger didn't affect the result. I did add DEBUG logging, but unfortunately this is all I get prior to the exception:
DEBUG:amqpy:amqpy 0.11.0 Connection.__init__()
I'll do some more fooling with it tomorrow and see what I can track down.
https://qpid.apache.org/components/cpp-broker/index.html
After revisiting that page, it appears that the C++ broker only supports AMQP 0.10 and AMQP 1.0, which are not the most popular protocols. The Java broker supports AMQP 0.9.1.
So this is not a bug, just an incompatible AMQP version. All the big servers (RabbitMQ, Qpid Java, and others) all support 0.9.1.
Ahh - you are correct, my fault. I mistakenly assumed that the cpp broker was compatible with both 0.9.1 and 1.0.
Yeah, AMQP version numbers were so poorly chosen. Decent protocol though.
What am I doing wrong here?
Packet log shows some chatter before the error: