Skip to content

authz: Add basic LRU cache with expiry to SubRepoPermsClient

Administrator requested to merge 503/basic-caching into main

Created by: ryanslade

We expect reqeusts from particular users to be bursty and it therefore makes sense to cache their sub-repo permissions for a short period of time in our long lived client's cache.

A WithGetter method was added to SubRepoPermsClient so that an instance with a persistent cache can have different db connections inserted.

Closes https://github.com/sourcegraph/sourcegraph/issues/26663

Merge request reports

Loading