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

Disconnect in message handlers

Since we are using exclusive queue, simply disconnect from it will
remove the queue
parent 1ecdc19f
No related branches found
No related tags found
1 merge request!116Update code regarding rcrmq class change
...@@ -34,7 +34,7 @@ if args.email == "": ...@@ -34,7 +34,7 @@ if args.email == "":
def timeout_handler(signum, frame): def timeout_handler(signum, frame):
print("Process timeout, there's might some issue with agents") print("Process timeout, there's might some issue with agents")
rc_util.rc_rmq.stop_consume() rc_util.rc_rmq.disconnect()
def callback(channel, method, properties, body): def callback(channel, method, properties, body):
...@@ -49,8 +49,7 @@ def callback(channel, method, properties, body): ...@@ -49,8 +49,7 @@ def callback(channel, method, properties, body):
for err in errmsg: for err in errmsg:
print(err) print(err)
rc_util.rc_rmq.stop_consume() rc_util.rc_rmq.disconnect()
rc_util.rc_rmq.delete_queue()
rc_util.add_account( rc_util.add_account(
......
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