mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 20:11:54 +00:00
This does a few things to further clean up RepositoryResolver: - It splits NewMinimalRepositoryResolver out of NewRepositoryResolver to make it more obvious when we're creating a fully-resolved RepositoryResolver and a lazy RepositoryResolver. It's pretty error prone to pass in a *types.Repo with only the Name and ID fields set. - It moves the always-available fields ID and Name directly onto the struct to make it more clear that those are safe to use directly - It refactors the lazy hydration to the more standard sync.Once pattern - It changes a bunch of call sites to use api.RepoName instead of *types.Repo when a fully-resolved repo is not actually needed (removing a few DB calls in the process) |
||
|---|---|---|
| .. | ||
| autoindexing | ||
| codenav | ||
| context | ||
| dependencies | ||
| policies | ||
| ranking | ||
| resolvers | ||
| sentinel | ||
| shared | ||
| types | ||
| uploads | ||
| BUILD.bazel | ||
| CODENOTIFY | ||
| services.go | ||