'Get the first available message from the queue.
Before it does so it acquires a lock on the store so
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.'

def _get(self, queue, timeout=None):

    with self._queue_lock(queue):
        key = self._key_prefix(queue)
        logger.debug(u'Fetching    key    %s    with    index    %s', key, self.index)
        try:
            result = self.client.read(key=key, recursive=True, index=self.index, timeout=self.timeout)
            if (result is None):
                raise Empty()
            item = result._children[(-1)]
            logger.debug(u'Removing    key    {0}'.format(item[u'key']))
            msg_content = loads(item[u'value'])
            self.client.delete(key=item[u'key'])
            return msg_content
        except (TypeError, IndexError, etcd.EtcdException) as error:
            logger.debug(u'_get    failed:    {0}:{1}'.format(type(error), error))
        raise Empty()
