Permalink
Browse files

long polling supported

  • Loading branch information...
1 parent 34ab785 commit bc00a998e6f7305b76c35a6a26dd6fcb402e4833 @maxcountryman maxcountryman committed May 9, 2014
Showing with 3 additions and 1 deletion.
  1. +3 −1 iron_mq.py
View
@@ -90,7 +90,7 @@ def post(self, *messages):
return result['body']
- def get(self, max=None, timeout=None):
+ def get(self, max=None, timeout=None, wait=None):
"""Executes an HTTP request to get a message off of a queue.
Keyword arguments:
@@ -102,6 +102,8 @@ def get(self, max=None, timeout=None):
qitems["n"] = max
if timeout is not None:
qitems["timeout"] = timeout
+ if wait is not None:
+ qitems["wait"] = wait
qs = []
for k, v in qitems.items():
qs.append("%s=%s" % (k, v))

0 comments on commit bc00a99

Please sign in to comment.