Skip to content
Snippets Groups Projects
Commit 201ebab8 authored by John Chilton's avatar John Chilton
Browse files

Improve client queue handling at shutdown.

 - Don't ack requeued messages (missing return seems like it was a bug).
 - More logging around this event.
parent 1a324745
No related branches found
No related tags found
No related merge requests found
......@@ -96,7 +96,13 @@ class MessageQueueClientManager(object):
def callback_wrapper(body, message):
if not self.active:
message.requeue()
log.debug("Obtained update message for inactive client manager, attempting requeue.")
try:
message.requeue()
log.debug("Requeue succeeded, will likely be handled next time consumer is enabled.")
except Exception:
log.debug("Requeue failed, message may be lost?")
return
try:
if "job_id" in body:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment