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

Convert the Agent JWT Cache into a fixed entry count cache #4891

Open
edwbuck opened this issue Feb 16, 2024 · 0 comments · May be fixed by #5633
Open

Convert the Agent JWT Cache into a fixed entry count cache #4891

edwbuck opened this issue Feb 16, 2024 · 0 comments · May be fixed by #5633
Assignees
Labels
priority/backlog Issue is approved and in the backlog

Comments

@edwbuck
Copy link
Contributor

edwbuck commented Feb 16, 2024

Currently the Agent JWT caching system holds all of the JWTs that have been requested, until they expire.

This issue would convert the cache to one of a specific fixed size.

The size should be measured by the count of the JWTs present.

Upon JWT request by a workload, the cache is accessed. If a suitable JWT exists in the cache, it is returned (the short path of handling the Workload API request). When the cache lacks the required JWT, a new JWT is generated by way of communications to the Server, and as part of returning the JWT to the Workload, the new JWT is inserted into the Agent JWT cache.

When inserting into a non-full cache, an empty slot in the cache accepts the JWT.
When inserting into a full cache, the JWT with the least amount of remaining utility is evicted from the cache, and the new entry is inserted.

The cache may or may not evict expired entries outside of a typical fetch / insert operation depending on team decision / ease of implementation.

@azdagron azdagron added the triage/in-progress Issue triage is in progress label Feb 20, 2024
@amartinezfayo amartinezfayo added priority/backlog Issue is approved and in the backlog and removed triage/in-progress Issue triage is in progress labels Feb 27, 2024
@sorindumitru sorindumitru linked a pull request Nov 5, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority/backlog Issue is approved and in the backlog
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants