beaker.ext.redisclusternm – Redis cluster NameSpace Manager and Synchronizer

Module Contents

class beaker.ext.redisclusternm.RedisClusterNamespaceManager(namespace, urls, timeout=None, **kwargs)

Provides the NamespaceManager API over Redis cluster.

Provided urls can be both multiple redis connection strings separated by a comma or an already existing RedisCluster instance.

Unlike a StrictRedis connection string, a RedisCluster one does not support database indicators, it is zero by default.

Example: redis://node-1:7001,redis://node-2:7002

Additional options can be passed in kwargs (e.g. username="redis", password="secure_password").

The data will be stored into redis keys, with their name starting with beaker_cache:.

class beaker.ext.redisclusternm.RedisClusterSynchronizer(identifier, urls, nodes=None, **kwargs)

Synchronizer based on redis cluster.

Provided urls can be both multiple redis connection strings separated by a comma or an already existing RedisCluster instance.

Unlike a StrictRedis connection string, a RedisCluster one does not support database indicators, it is zero by default.

Example: redis://node-1:7001,redis://node-2:7002

This Synchronizer only supports 1 reader or 1 writer at time, not concurrent readers.