Have blob mounting use the blob cache

This commit is contained in:
Joseph Schorr 2019-02-14 13:06:18 -05:00
parent f75f315037
commit 69c306e740
2 changed files with 24 additions and 2 deletions

View file

@ -132,7 +132,8 @@ def _try_to_mount_blob(repository_ref, mount_blob_digest):
return None
# Lookup if the mount blob's digest exists in the repository.
mount_blob = registry_model.get_repo_blob_by_digest(from_repository_ref, mount_blob_digest)
mount_blob = registry_model.get_cached_repo_blob(model_cache, from_namespace, from_repo_name,
mount_blob_digest)
if mount_blob is None:
logger.debug('Blob `%s` under repository `%s` not found', mount_blob_digest, from_repo)
return None