Skip to content

Initial cache setup for auth information. - #1841

Open
MikeNeilson wants to merge 2 commits into
developfrom
devops/cache-user-info
Open

Initial cache setup for auth information.#1841
MikeNeilson wants to merge 2 commits into
developfrom
devops/cache-user-info

Conversation

@MikeNeilson

@MikeNeilson MikeNeilson commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Reduce database load per request by caching DataPrincipal objects for some amount of time
before reloading from the database.

The TTL is "fixed", e.g. after the timeout the value is remove regardless of usage. This so that we don't over cache principal objects in case of removed credentials.
The LRU portion is so that the map object has bounded memory.

NOTE: I do not expect this to work well or be used for time series caching, that requires some more complexity.

Related Issue

No open issue

Validation

General usage within the API.

TODO:

  • Individual test of LruTtlCache will be created.

caching does work, but some issues with behavior definitely indicate some specific formal tests are required. Will get to those eventually, and any comments about it welcome. Design commentary definitely welcome.

Checklist

  • AI tools used

@MikeNeilson
MikeNeilson force-pushed the devops/cache-user-info branch from a0303a6 to a369ab9 Compare July 16, 2026 17:28
@MikeNeilson
MikeNeilson force-pushed the devops/cache-user-info branch 2 times, most recently from eb9331f to ae9a53e Compare August 7, 2026 17:50
@MikeNeilson
MikeNeilson force-pushed the devops/cache-user-info branch 2 times, most recently from 84ed992 to c941980 Compare August 20, 2026 22:24
@MikeNeilson
MikeNeilson marked this pull request as ready for review August 24, 2026 15:21
@MikeNeilson
MikeNeilson force-pushed the devops/cache-user-info branch from c941980 to 546239b Compare August 24, 2026 15:21
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.

1 participant