summaryrefslogtreecommitdiff
path: root/heat/engine/clients
diff options
context:
space:
mode:
authorrabi <ramishra@redhat.com>2016-06-01 12:29:09 +0530
committerrabi <ramishra@redhat.com>2016-06-01 12:34:02 +0530
commit4f3bdcc9907a2533c85ecaee053725f262eb2e2e (patch)
tree90c576fb0d9bfde6de4070ff1ed71b4a3eb37f48 /heat/engine/clients
parent2c05a6132854166e1f799927954715f554968247 (diff)
downloadheat-4f3bdcc9907a2533c85ecaee053725f262eb2e2e.tar.gz
Use get_auth_ref() rather than auth_ref property
Some plugins like Token does not have this property. It's better to use get_auth_ref method. Change-Id: Ib1de63d692b29179503b65f4b38461e2b82b7be8
Diffstat (limited to 'heat/engine/clients')
-rw-r--r--heat/engine/clients/client_plugin.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/heat/engine/clients/client_plugin.py b/heat/engine/clients/client_plugin.py
index 17347b710..8d1eb89db 100644
--- a/heat/engine/clients/client_plugin.py
+++ b/heat/engine/clients/client_plugin.py
@@ -142,8 +142,10 @@ class ClientPlugin(object):
version = self.default_version
if version in self._client_instances:
+ auth_ref = self.context.auth_plugin.get_auth_ref(
+ self._keystone_session)
if (cfg.CONF.reauthentication_auth_method == 'trusts'
- and self.context.auth_plugin.auth_ref.will_expire_soon(
+ and auth_ref.will_expire_soon(
cfg.CONF.stale_token_duration)):
# If the token is near expiry, force creating a new client,
# which will get a new token via another call to auth_token