<div dir="ltr">I have several consumers that could have exceptions raised while they are processing a message. Right now I catch any exceptions and restart the consumer (gracefully close the channel & connection, then in the same process setup a new client). For some known errors I might also wait some time between closing a connection and reconnecting.<div>
<br></div><div>What I want to do is, if a message was received but not acknowledged when an exception is raised, "requeue" the message at the front of the queue so it is retried immediately on any consumer (even the consumer that just failed). Is there a preferred way to do this?</div>
<div><br></div><div>I tried not acknowledging the message at all, closing the channel and connection and reconnecting and the unacknowledged message was not resent for exactly 600 seconds. I am using pika/python if that matters. I have had good luck with sending a recover before closing the connection as well - I see the message sent again with requeue=False, but it will only retry the messages 2x. I haven't had any luck using nack or reject. Any suggestions?</div>
<div><div><div><div><br></div>-- <br><span style="font-family:Helvetica,Arial,sans-serif;font-size:14px;line-height:16px">Charles Law</span> <span style="font-family:Helvetica,Arial,sans-serif;font-size:11px;font-style:italic;line-height:13px">Software Developer</span><div>
Watch how we make online advertising simple: <a href="http://bit.ly/Ent_vid" style="color:rgb(0,114,188);text-decoration:none" target="_blank">http://bit.ly/Ent_vid</a></div><div><a href="http://www.openx.org/" style="color:rgb(0,114,188);text-decoration:none" target="_blank">www.openx.com</a> | follow us on: <a href="http://twitter.com/openx" style="color:rgb(0,114,188);text-decoration:none" target="_blank">Twitter</a> <a href="http://www.facebook.com/OpenX" style="color:rgb(0,114,188);text-decoration:none" target="_blank">Facebook</a> <a href="http://www.linkedin.com/company/openx/products" style="color:rgb(0,114,188);text-decoration:none" target="_blank">LinkedIn</a>
</div>
</div></div></div></div>