Container Registry: Use Redis repository object cache across all API operations
## Context In https://gitlab.com/gitlab-org/container-registry/-/issues/461+, we've implemented support for caching repository objects from the metadata database on Redis. Then, in https://gitlab.com/gitlab-org/container-registry/-/merge_requests/1086+, we've started by enabling this cache for the [get repository details](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs-gitlab/api.md#get-repository-details) API endpoint. Today we just completed the deployment of a new Redis cache instance for the container registry on GitLab.com ( https://gitlab.com/gitlab-com/gl-infra/scalability/-/issues/1953), which is now being actively used for the first use case (get repository details operation). This means we're ready to start extending the use of this cache to all other relevant API operations, one by one, to reduce risk. We should release and deploy them one by one to GitLab.com so that we can observe their effect in isolation. ## Task Follow the example of https://gitlab.com/gitlab-org/container-registry/-/merge_requests/1086 and enable the use of the cache for the following API operations. Please respect this sequence as it's meant to start with lower rate/risk operations: 1. [x] OCI v2 [blob link delete](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#deleting-a-layer) 2. [x] OCI v2 [cancel blob upload](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#canceling-an-upload) 3. [x] OCI v2 [blob upload progress](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#upload-progress) 4. [x] OCI v2 [cross repository blob mount](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#cross-repository-blob-mount) 5. [x] OCI v2 [start blob upload](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#starting-an-upload) 6. [x] OCI v2 [complete blob upload](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#completed-upload) 7. [x] OCI v2 [blob chunk upload](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#chunked-upload) 8. [x] OCI v2 [manifest upload](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#pushing-an-image-manifest) 9. [x] OCI v2 [manifest delete](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#deleting-an-image) 11. [x] GitLab v1 [list repository tags](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/gitlab/api.md#list-repository-tags) 10. [x] OCI v2 [tag delete](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#deleting-a-tag) 13. [x] OCI v2 [check blob](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#existing-layers) 15. [x] OCI v2 [blob download](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#pulling-a-layer) 12. [x] OCI v2 [tag list](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#listing-image-tags) 14. [x] OCI v2 [manifest download](https://gitlab.com/gitlab-org/container-registry/-/blob/master/docs/spec/docker/v2/api.md#pulling-an-image-manifest) Once the Redis cache has fully replaced the single repository one: * \[ \] Initialize repository cache using the Redis cache implementation centrally, [here](https://gitlab.com/gitlab-org/container-registry/blob/3a2d127342dda53540d3fd28a380d70507f4bad1/registry/handlers/app.go#L1153-1153), and remove such logic from the individual handlers.
epic