bug fix (updating pika interface)

pull/1/head
Steve L. Nyemba 5 years ago
parent 1bb7c1bd0a
commit 834dc80e79

@ -8,7 +8,7 @@ def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read() return open(os.path.join(os.path.dirname(__file__), fname)).read()
args = { args = {
"name":"data-transport", "name":"data-transport",
"version":"1.1.0", "version":"1.1.2",
"author":"The Phi Technology LLC","author_email":"info@the-phi.com", "author":"The Phi Technology LLC","author_email":"info@the-phi.com",
"license":"MIT", "license":"MIT",
"packages":["transport"]} "packages":["transport"]}

@ -142,7 +142,7 @@ class QueueReader(MessageQueue,Reader):
#self.exchange = params['uid'] #self.exchange = params['uid']
#self.queue = params['qid'] #self.queue = params['qid']
MessageQueue.__init__(self,**params); MessageQueue.__init__(self,**params);
self.init() # self.init()
if 'durable' in params : if 'durable' in params :
self.durable = True self.durable = True
else: else:
@ -198,13 +198,14 @@ class QueueReader(MessageQueue,Reader):
# #
if isinstance(self.queue,str) : if isinstance(self.queue,str) :
self.queue = [self.queue] self.queue = [self.queue]
for qid in self.queue: for qid in self.queue:
self.init(qid) self.init(qid)
# r[qid] = [] # r[qid] = []
if self.qhandler.method.message_count > 0: if self.qhandler.method.message_count > 0:
self.channel.basic_consume(self.callback,queue=qid,no_ack=False); self.channel.basic_consume(queue=qid,on_message_callback=self.callback,auto_ack=False);
self.channel.start_consuming() self.channel.start_consuming()
else: else:

Loading…
Cancel
Save