diff options
author | Zuul <zuul@review.openstack.org> | 2018-05-04 16:59:08 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2018-05-04 16:59:08 +0000 |
commit | a21123c384e6ff11269b7e6056f940de48413cab (patch) | |
tree | 8fced867fea231a62babb9fb021264e3bc9a9403 | |
parent | 6e68f597a5e5a6db86b44fe089a0225562886674 (diff) | |
parent | e65033910714d6f7d198d8eff6997fdaec102474 (diff) | |
download | os-client-config-a21123c384e6ff11269b7e6056f940de48413cab.tar.gz |
Merge "Add cache methods back to OpenSackConfig"1.31.1
-rw-r--r-- | os_client_config/config.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/os_client_config/config.py b/os_client_config/config.py index d506a04..721528d 100644 --- a/os_client_config/config.py +++ b/os_client_config/config.py @@ -27,6 +27,27 @@ class OpenStackConfig(loader.OpenStackConfig): get_one_cloud = loader.OpenStackConfig.get_one get_all_clouds = loader.OpenStackConfig.get_all + def get_cache_expiration_time(self): + return int(self._cache_expiration_time) + + def get_cache_interval(self): + return self.get_cache_expiration_time() + + def get_cache_max_age(self): + return self.get_cache_expiration_time() + + def get_cache_path(self): + return self._cache_path + + def get_cache_class(self): + return self._cache_class + + def get_cache_arguments(self): + return copy.deepcopy(self._cache_arguments) + + def get_cache_expiration(self): + return copy.deepcopy(self._cache_expiration) + if __name__ == '__main__': config = OpenStackConfig().get_all_clouds() |