Skip to main content

A persistent, (mostly) atomic queue (like deque or Queue) implemented with redis backing.

Project description

redis_queue is useful for implementing a multi-producer,

multi-consumer job queue. While it doesn’t have all the handy blocking and locking features of Queue, it does have the advantages of being multi-process safe and persistant.

Example Usage:::
>>> from redis import Redis
>>> from redis_queue import Queue
>>> redis = Redis(host='127.0.0.1', port=6379)
>>> queue = Queue(redis, 'test_queue')
>>> queue.append('one')
>>> queue.append('two')
>>> queue.append('three')
>>> queue.pop()
'three'
>>> queue.pop()
'two'
>>> queue.pop()
'one'
>>> queue.append('one')
>>> queue.append('two')
>>> queue.append('three')
>>> queue.popleft()
'one'
>>> queue.popleft()
'two'
>>> queue.popleft()
'three'

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

redis_queue-0.3.tar.gz (7.4 kB view details)

Uploaded Source

File details

Details for the file redis_queue-0.3.tar.gz.

File metadata

  • Download URL: redis_queue-0.3.tar.gz
  • Upload date:
  • Size: 7.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for redis_queue-0.3.tar.gz
Algorithm Hash digest
SHA256 cafb83bb4a11d2b75bac14934cff6842fbe44a378405e04b7f41a5078d192961
MD5 1ad215290bb45c3b0526a01475a61784
BLAKE2b-256 9ef91af47da2d15e7fb4bdab82f62e8e4ec0056f17d57cd9496c29374a505792

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page