namespaced subset of your redis keyspace
Project description
redis-namespace
redis-namespace for python
Redis namespace provides an interface to a namespaced subset of your redis keyspace (e.g., keys with a common beginning), and requires the redis-py.
import redis
from redis_namespace import StrictRedis
redis_connection = redis.StrictRedis()
namespaced_redis = StrictRedis(namespace='ns:')
namespaced_redis.set('foo', 'bar') # redis_connection.set('ns:foo', 'bar')
namespaced_redis.get('foo')
redis_connection.get('ns:foo')
namespaced_redis.delete('foo')
namespaced_redis.get('foo')
redis_connection.get('ns:foo')
Installation
pip install redis-namespace
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
Built Distributions
Close
Hashes for redis_namespace-3.0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 49a6fbf03093737ad40e05933f2c9cd57e12f30740f83198d5ae3e3b0fe1ce2d |
|
MD5 | aefb19ad2a4e9c74bb725d822429e5ee |
|
BLAKE2b-256 | 55e91ed958be59589c3d17889e00d0c55103cb5e38341de217a8021d544d19f9 |
Close
Hashes for redis_namespace-3.0.1.1-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6824b73d4dc7880f7e5e28beea0b3f67e12aa081d3ab0f083f6f21d1d22a7676 |
|
MD5 | 447104bed3fb241b072bc78c6d584b1d |
|
BLAKE2b-256 | a19fcdf67a440602daa7bacf86b8acdebdb06036d65185706d6d5111f4c279da |