Bases: object
Basic KVS manager object to support Keystone Key-Value-Store systems.
This manager also supports the concept of locking a given key resource to allow for a guaranteed atomic transaction to the backend.
Configure the KeyValueStore instance.
Parameters: |
|
---|
Delete a single key from the KVS backend.
This method will raise NotFound if the key doesn’t exist. The get and delete are done in a single transaction (via KeyValueStoreLock mechanism).
Delete multiple keys from the KVS backend in a single call.
Like set_multi, this call does not serialize through the KeyValueStoreLock mechanism (locking cannot occur on more than one key in a given context without significant deadlock potential).
Get a write lock on the KVS value referenced by key.
The ability to get a context manager to pass into the set/delete methods allows for a single-transaction to occur while guaranteeing the backing store will not change between the start of the ‘lock’ and the end. Lock timeout is fixed to the KeyValueStore configured lock timeout.
Bases: object
Basic KeyValueStoreLock context manager.
Hooks into the dogpile.cache backend mutex allowing for distributed locking on resources. This is only a write lock, and will not prevent reads from occurring.
Bases: keystone.exception.UnexpectedError
Retrieve key value store.
Instantiate a new KeyValueStore or return a previous instantiation that has the same name.