0

We are using Carrot in our Python project. I wrote a Python script acting as the consumer of the message queue. I invoked this Python script using command line shell in Windows 7 as

python consumer.py

However, after a while, the running session was aborted and the error is:

[errno 10054] An existing connection was forcibly closed by the remote host

The producer session is still running fine on the Linux server. Just wondering how can I fix this and have a long running consumer session on Windows .

Kara
  • 6,115
  • 16
  • 50
  • 57
Meditation
  • 31
  • 1
  • 3

1 Answers1

0

I don't know Carrot/AMQP, but I'd first of all check if the AMQP server logged an error at the time your client got disconnected. It could be that you just have to expect these errors to occur from time to time and upon disconnection, catch the exception(?) and reestablish the connection.

aknuds1
  • 65,625
  • 67
  • 195
  • 317
  • The AMQP server/producer is running fine without any errors and exceptions, only the consumer got this error and disconnected from time to time. – Meditation Jan 10 '11 at 23:18
  • In that case, I suspect you should handle the error in your Python client and reestablish the connection. That is, if Carrot's design allows you to recover smoothly from such hiccups. – aknuds1 Jan 11 '11 at 07:18