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

Fetch OIDC token in the background process to avoid expiration issue #2669

Merged
merged 14 commits into from
Apr 12, 2024

Conversation

iamrk04
Copy link
Contributor

@iamrk04 iamrk04 commented Apr 10, 2024

The OID token expires after 5 mins and hence all of our test fails with the following error:

ERROR: AADSTS700024: Client assertion is not within its valid time range. Current time: 2024-04-10T19:14:34.7127519Z, assertion valid from 2024-04-10T18:54:41.0000000Z, expiry time of assertion 2024-04-10T18:59:41.0000000Z.

I propose to fix this by fetching this token every 4 mins. For more details on the issue, please check this issue.

Copy link

github-actions bot commented Apr 10, 2024

Test Results for assets-test

18 tests   18 ✅  33m 18s ⏱️
 1 suites   0 💤
 1 files     0 ❌

Results for commit 2bf0310.

♻️ This comment has been updated with latest results.

@iamrk04 iamrk04 changed the title Acquire access token before ID token expires Fetch OID token every 4 mins to avoid expiration issue Apr 11, 2024
@iamrk04 iamrk04 marked this pull request as ready for review April 11, 2024 06:45
@iamrk04 iamrk04 requested a review from a team as a code owner April 11, 2024 06:45
@iamrk04 iamrk04 enabled auto-merge (squash) April 11, 2024 15:19
@iamrk04 iamrk04 changed the title Fetch OID token every 4 mins to avoid expiration issue Fetch OIDC token in the background process to avoid expiration issue Apr 12, 2024
@iamrk04 iamrk04 merged commit 2e961ac into main Apr 12, 2024
1 check passed
@iamrk04 iamrk04 deleted the rk/fix_token_expiry branch April 12, 2024 18:56
elesel pushed a commit that referenced this pull request Apr 23, 2024
* acquire access token before expiry

* temp change to trigger test

* add requested url

* print the current time as well

* update when to get token

* Revert "temp change to trigger test"

This reverts commit b9dc55da738e07b24a03629188e4f17f3f9df409.

* prevent logging token

* temp bump version to trigger test

* Revert "prevent logging token"

This reverts commit 7872d09ae087689f7d8e0a45b99a329c18b08a7d.

* try switching to resource

* try fetching OID token every 4 mins

* Revert "temp bump version to trigger test"

This reverts commit dd27330d9c71e940fbef147155cfc5d00963f9c5.
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

Successfully merging this pull request may close these issues.

2 participants