Skip to content
Snippets Groups Projects
Commit 3a0474f4 authored by Bo-Chun Chen's avatar Bo-Chun Chen
Browse files

Send confirmation at the end of task

parent 63389215
No related branches found
No related tags found
6 merge requests!147Merge previous default branch feat-cod-rmq into main,!85kill nginx process running under user from login node,!51Fix acct create wait,!39WIP:Feat cod rmq,!38WIP: Feat cod rmq,!24Add notify user agent
......@@ -39,15 +39,14 @@ def notify_user(ch, method, properties, body):
except Exception as exception:
logger.error('', exc_info=True)
# acknowledge the message
ch.basic_ack(delivery_tag=method.delivery_tag)
# send confirm message
rc_rmq.publish_msg({
'routing_key': 'confirm.' + username,
'msg': msg
})
# acknowledge the message
ch.basic_ack(delivery_tag=method.delivery_tag)
if __name__ == "__main__":
logger.info(f'Start listening to queue: {task}')
......
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