]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Check context before returning cached value
authorDave McCowan <dmccowan@cisco.com>
Mon, 7 Dec 2015 19:25:24 +0000 (14:25 -0500)
committerDave McCowan <dmccowan@cisco.com>
Wed, 9 Dec 2015 01:51:48 +0000 (20:51 -0500)
commit0832a0355381229ece235440a9c5de1301e51d07
tree4a7fcb5e522f57e821c4b8e99a86e8a9ccf48f4f
parentef08af911244210b5b7839502302a90199b14263
Check context before returning cached value

The key manager caches the value of barbican client to be reused,
saving an extra call to keystone.  The cached value is only
applicable to the current context, so the context must be checked
before returning the cached value.

Change-Id: Ib10909a098fb2cd070129c239b6d3b95edc8fea0
Closes-Bug: #1523646
cinder/keymgr/barbican.py
cinder/tests/unit/keymgr/test_barbican.py