From fc9f622cba6b6671f5b5f0371de9bf31ae75c7d1 Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Wed, 22 Jan 2025 11:55:59 +0100 Subject: Git CAS access: reduce log level Trying to access a git object return a recoverable failure, hence the failure to find the object in the git object database should be logged at warning level at most. Moreover, in some cases we should log that event at an even lower level, e.g., if we're just checking the presence of the object in the local git cas to avoid unnecessary network access. --- src/buildtool/execution_api/git/git_api.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/buildtool/execution_api/git/git_api.hpp') diff --git a/src/buildtool/execution_api/git/git_api.hpp b/src/buildtool/execution_api/git/git_api.hpp index 64e3bd16..a6ad4196 100644 --- a/src/buildtool/execution_api/git/git_api.hpp +++ b/src/buildtool/execution_api/git/git_api.hpp @@ -323,7 +323,8 @@ class GitApi final : public IExecutionApi { [[nodiscard]] auto IsAvailable(ArtifactDigest const& digest) const noexcept -> bool override { - return repo_config_->ReadBlobFromGitCAS(digest.hash()).has_value(); + return repo_config_->ReadBlobFromGitCAS(digest.hash(), LogLevel::Trace) + .has_value(); } [[nodiscard]] auto IsAvailable(std::vector const& digests) -- cgit v1.2.3