diff options
author | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2013-08-07 11:37:38 -0400 |
---|---|---|
committer | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2013-08-07 13:28:47 -0400 |
commit | 7e9787c947e99b68317f5420951a296cea858daa (patch) | |
tree | ebd7605737b8e9a9a35a8bfa58adf312c9fa0c49 /src/lib/Bcfg2/Server/Plugin | |
parent | 441a96457ba55529c0316a7459dcb295988824b0 (diff) | |
download | bcfg2-7e9787c947e99b68317f5420951a296cea858daa.tar.gz bcfg2-7e9787c947e99b68317f5420951a296cea858daa.tar.bz2 bcfg2-7e9787c947e99b68317f5420951a296cea858daa.zip |
Plugin: added new Caching interface
This gives a single unified interface for expiring caches, no matter
the plugin. This will be particularly useful with the
MultiprocessingCore, as certain calls must be dispatched to child
processes to expire their caches.
Diffstat (limited to 'src/lib/Bcfg2/Server/Plugin')
-rw-r--r-- | src/lib/Bcfg2/Server/Plugin/interfaces.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/Bcfg2/Server/Plugin/interfaces.py b/src/lib/Bcfg2/Server/Plugin/interfaces.py index 222b94fe3..2dbf75f42 100644 --- a/src/lib/Bcfg2/Server/Plugin/interfaces.py +++ b/src/lib/Bcfg2/Server/Plugin/interfaces.py @@ -598,3 +598,11 @@ class ClientRunHooks(object): :returns: None """ pass + + +class Caching(object): + """ A plugin that caches more than just the data received from the + FAM. This presents a unified interface to clear the cache. """ + + def expire_cache(self, key=None): + raise NotImplementedError |