Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apigee NG requires that the cache entry has an expiry time for a cache resource #144

Closed
davidmitchell2019 opened this issue Jan 6, 2021 · 7 comments

Comments

@davidmitchell2019
Copy link

Apigee NG requires that the cache entry has an expiry time for a cache resource.
When the shared flow does a lookup on the cache entry it exists, but when the set am header policy tries to add the bearer token it cant find the entry

@davidmitchell2019
Copy link
Author

davidmitchell2019 commented Jan 6, 2021

cache access token policy below

@davidmitchell2019
Copy link
Author

<PopulateCache name="PCCacheAccessToken"> <CacheKey> <Prefix>gcp.sa</Prefix> <KeyFragment ref="private.gcp.service_account.client_id"/> <KeyFragment ref="token.purpose"/> </CacheKey> <CacheResource>gcp-tokens</CacheResource> <Source>private.gcp.access_token</Source> <ExpirySettings> <TimeoutInSec>600</TimeoutInSec> </ExpirySettings> </PopulateCache>

@davidmitchell2019
Copy link
Author

Screenshot 2021-01-06 at 13 28 55

@davidmitchell2019
Copy link
Author

So the lookup still finds the entry even tho the entry has expired

@tyayers
Copy link
Contributor

tyayers commented Jan 6, 2021

Maybe an issue with TimeoutInSec, which is deprecated? Try TimeoutInSeconds, haven't tested it yet but could be the problem..

@davidmitchell2019
Copy link
Author

Syntax error on my behalf, have a great day :-)

@danistrebel
Copy link
Collaborator

Thanks for reporting this. I can confirm the requirement for the ExpirySettings entry.

I am a bit worried because the validation only allows for the deprecated TimeoutInSec instead of TimeoutInSeconds. I'll look into this and make some adjustment to the sharedflow based on that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants