The zaqar.storage.redis.queues module

class QueueController(*args, **kwargs)

Bases: zaqar.storage.base.Queue

Implements queue resource operations using Redis.

Queues are scoped by project, which is prefixed to the queue name.

Redis Data Structures:

  1. Queue Index (Redis sorted set):

    Set of all queues for the given project, ordered by name.

    Key: <project_id>.queues_set

    Id Value
    name <project_id>.<queue_name>
  2. Queue Information (Redis hash):

    Key: <project_id>.<queue_name>

    Name Field
    metadata m
    creation timestamp t
get_metadata(*args, **kwargs)
set_metadata(*args, **kwargs)