diff options
Diffstat (limited to 'kombu/transport/etcd.py')
-rw-r--r-- | kombu/transport/etcd.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/kombu/transport/etcd.py b/kombu/transport/etcd.py index 2ab85841..aa4771b7 100644 --- a/kombu/transport/etcd.py +++ b/kombu/transport/etcd.py @@ -78,6 +78,7 @@ class Channel(virtual.Channel): """Create and return the `queue` with the proper prefix. Arguments: + --------- queue (str): The name of the queue. """ return f'{self.prefix}/{queue}' @@ -93,6 +94,7 @@ class Channel(virtual.Channel): means that they have to wait before the lock is released. Arguments: + --------- queue (str): The name of the queue. """ lock = etcd.Lock(self.client, queue) @@ -109,6 +111,7 @@ class Channel(virtual.Channel): """Create a new `queue` if the `queue` doesn't already exist. Arguments: + --------- queue (str): The name of the queue. """ self.queues[queue] = queue @@ -123,7 +126,8 @@ class Channel(virtual.Channel): def _has_queue(self, queue, **kwargs): """Verify that queue exists. - Returns: + Returns + ------- bool: Should return :const:`True` if the queue exists or :const:`False` otherwise. """ @@ -137,6 +141,7 @@ class Channel(virtual.Channel): """Delete a `queue`. Arguments: + --------- queue (str): The name of the queue. """ self.queues.pop(queue, None) @@ -148,6 +153,7 @@ class Channel(virtual.Channel): This simply writes a key to the Etcd store Arguments: + --------- queue (str): The name of the queue. payload (dict): Message data which will be dumped to etcd. """ @@ -166,6 +172,7 @@ class Channel(virtual.Channel): only one node reads at the same time. This is for read consistency Arguments: + --------- queue (str): The name of the queue. timeout (int): Optional seconds to wait for a response. """ @@ -196,6 +203,7 @@ class Channel(virtual.Channel): """Remove all `message`s from a `queue`. Arguments: + --------- queue (str): The name of the queue. """ with self._queue_lock(queue): @@ -207,6 +215,7 @@ class Channel(virtual.Channel): """Return the size of the `queue`. Arguments: + --------- queue (str): The name of the queue. """ with self._queue_lock(queue): |