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

Refresh JWT tokens earlier #8

Open
hjacobs opened this issue Mar 2, 2016 · 1 comment
Open

Refresh JWT tokens earlier #8

hjacobs opened this issue Mar 2, 2016 · 1 comment

Comments

@hjacobs
Copy link
Contributor

hjacobs commented Mar 2, 2016

All tokens are only refreshed 20 minutes before their expiration time (https://github.com/zalando-stups/python-tokens/blob/master/tokens/__init__.py#L14). We need to make this dynamic to refresh earlier for JWT tokens.

@hjacobs
Copy link
Contributor Author

hjacobs commented Mar 2, 2016

NOTE: The Java tokens library refreshes as soon as 40% of validity time are left (https://github.com/zalando-stups/tokens/blob/master/src/main/java/org/zalando/stups/tokens/AccessTokensBuilder.java#L36), i.e. it will already try to refresh an 8 hours tokens after 4.8 hours.

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

No branches or pull requests

1 participant