[rabbitmq-discuss] Receiving errno 10054 (WSAECONNRESET) writing to queue

Sigurd Høgsbro sigurd.hogsbro at museeka.com
Tue Feb 9 05:41:26 GMT 2010


Matthias,

2010/2/8 Matthias Radestock <matthias at lshift.net>

> That indicates that the client closed the connection. Or the network died.

Yep; I also reached that conclusion.

>
>  I used to have immediate and mandatory flags set but I've removed
>> these to make the connection as plain vanilla as possible.
>>
>
> With these flags set the server may send 'basic.return' commands to the
> client. Perhaps amqplib doesn't handle these and dies?


As the problem manifests itself with a plain connection this is not likely
to be the cause.

>
> Also note that the frame size does not limit the message size, since
> messages can be split across multiple frames. All our supported client
> libraries do that automatically but it's possible that amqplib doesn't.


I've found out that pika takes the min() of the server-mandated framesize
(128k) and the one I specified in the ConnectionParameters() meaning that I
cannot set a larger frame-size.

>From reviewing the pika & amqplib code it seems that:
- pika takes the header/footer sizes into account when computing the
frame-max to use
- pika actually writes in frame-max blocks, which I don't believe amqplib
does. Not sure yet whether this could cause the issue observed.

When I finish translating my threaded amqplib app into pika using asyncore I
hope to find that it solves the problem.

>
>> Try to get a trace that includes the connection disappearance. The pattern
> of commands just prior to that might shed some light on what causes the
> client to trip up.


Tracer writes the full message-body to stdout which isn't helpful when
sending multi-megabyte bodies. I'll try using wireshark for diagnostics
instead.

>
> Feel free to give it a try, but since we do not know what the problem is
> there is no way to tell in advance whether it will fare any better.
>
> I like the design principles of pika, but the example of demo_relay.py is a
little hard going. Can you point me at any other real-world examples of
asyncore-based connection handling? And what is the recommended way to
detect/handle connection-failure?

Regards,

Sigurd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20100209/b2d9bd9c/attachment.htm 


More information about the rabbitmq-discuss mailing list