Remove GlobalRepos
Created by: camdencheek
This PR takes the steps needed to remove GlobalRepos, which is the last of our global stores 🥳
This PR comes in 5 commits:
- Convert all uses of
backend.Repos
intobackend.NewRepos()
. This is the meat of this PR. It requires making sure there is a db available to pass in, which is what #28120 enabled - Now that the only use of the global
Repos
value is to get its cache, unwrap it to just leave the cache. - In order to remove the last use of
GlobalRepos
, we need to be able to create anIndexableReposLister
with a shared cache and a passed-in db handle. This splits the cache type from the lister type so we can pass it in separately. -
GlobalRepos
is now unused, so remove it - Now that
GlobalRepos
is gone, we don't needensureStore
.
Also, this gets rid of one more reference todbconn.Global
that was used in ensureStore
methods.
1 down, 33 to go.
Stacked on #28118