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.4.tar.gz (7.5 kB view details)

Uploaded Source

File details

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

File metadata

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

File hashes

Hashes for redis_queue-0.4.tar.gz
Algorithm Hash digest
SHA256 5ea99cc380a0352830f6bcb1b74c916a41a2a439769e73e0680839868607bd0a
MD5 61ab11fbb3e6afa6160fb95d925a4be2
BLAKE2b-256 4180363cb3b902a228b9e49167e2d7bdd5eb02caa7a399da15771bf4cf6e4c34

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