diff options
author | Ask Solem <ask@celeryproject.org> | 2012-08-05 17:21:49 +0100 |
---|---|---|
committer | Ask Solem <ask@celeryproject.org> | 2012-08-05 17:21:55 +0100 |
commit | db1af567b26399c849dfa77be1d3917ebdca1455 (patch) | |
tree | 9abc21f05ff6f59f01d5e1b035f539d8727e9bbb | |
parent | 21279e71685ec76b7640d38afedc0048245ad79d (diff) | |
download | kombu-2.3-archived.tar.gz |
Adds back kombu.compat.entry_to_queue. Closes celery/celery#8322.3-archived
-rw-r--r-- | kombu/clocks.py | 4 | ||||
-rw-r--r-- | kombu/compat.py | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/kombu/clocks.py b/kombu/clocks.py index a45bc767..aecb68fb 100644 --- a/kombu/clocks.py +++ b/kombu/clocks.py @@ -11,7 +11,7 @@ Logical Clocks and Synchronization. from __future__ import absolute_import from __future__ import with_statement -from threading import Lock +import threading __all__ = ['LamportClock'] @@ -57,7 +57,7 @@ class LamportClock(object): def __init__(self, initial_value=0): self.value = initial_value - self.mutex = Lock() + self.mutex = threading.Lock() def adjust(self, other): with self.mutex: diff --git a/kombu/compat.py b/kombu/compat.py index 88874aad..88aedaa9 100644 --- a/kombu/compat.py +++ b/kombu/compat.py @@ -19,6 +19,9 @@ from .entity import Exchange, Queue __all__ = ['Publisher', 'Consumer'] +# XXX compat attribute +entry_to_queue = Queue.from_dict + def _iterconsume(connection, consumer, no_ack=False, limit=None): consumer.consume(no_ack=no_ack) |