Fix MostRecentProvider.encryption_materials() caching bug#102
Fix MostRecentProvider.encryption_materials() caching bug#102mattsb42-aws merged 8 commits intoaws:masterfrom mattsb42-aws:metastore
Conversation
|
Working on understanding the fix here. It seems that the original logic was this: check if ttl_action is TtlActions.LIVE, and if so return the given provider from the cache. Also, in this case return a provider instead of encryption materials like in the other cases. If it failed, set the ttl_action to EXPIRED and pull the provider from the local cache if thats allowed. If it's not allowed, miss the cache. Is it the case that this fixes the return types of the method to be consistent? And then, was there a problem with the cache returning None for its values? |
Yes. What used to happen was that the return type from This test[1] failing was what identified this issue. |
Description of changes:
A customer encountered a bug where
MostRecentProviderwas not actually using cached results. Upon investigation, this uncovered this bug where the provider was returning invalid results once the cache was populated.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.