summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/buildtool/execution_api/remote/bazel/bazel_cas_client.cpp36
-rw-r--r--src/buildtool/execution_api/remote/bazel/bazel_cas_client.hpp7
2 files changed, 0 insertions, 43 deletions
diff --git a/src/buildtool/execution_api/remote/bazel/bazel_cas_client.cpp b/src/buildtool/execution_api/remote/bazel/bazel_cas_client.cpp
index 762f8f5d..3cf7e845 100644
--- a/src/buildtool/execution_api/remote/bazel/bazel_cas_client.cpp
+++ b/src/buildtool/execution_api/remote/bazel/bazel_cas_client.cpp
@@ -351,42 +351,6 @@ auto BazelCasClient::BatchReadBlobs(
return result;
}
-auto BazelCasClient::GetTree(std::string const& instance_name,
- bazel_re::Digest const& root_digest,
- std::int32_t page_size,
- std::string const& page_token) const noexcept
- -> std::vector<bazel_re::Directory> {
- auto request =
- CreateGetTreeRequest(instance_name, root_digest, page_size, page_token);
-
- grpc::ClientContext context;
- bazel_re::GetTreeResponse response;
- auto stream = stub_->GetTree(&context, request);
-
- std::vector<bazel_re::Directory> result;
- while (stream->Read(&response)) {
- std::move(response.mutable_directories()->begin(),
- response.mutable_directories()->end(),
- std::back_inserter(result));
- auto const& next_page_token = response.next_page_token();
- if (not next_page_token.empty()) {
- // recursively call this function with token for next page
- auto next_result =
- GetTree(instance_name, root_digest, page_size, next_page_token);
- std::move(next_result.begin(),
- next_result.end(),
- std::back_inserter(result));
- }
- }
-
- auto status = stream->Finish();
- if (not status.ok()) {
- LogStatus(&logger_, LogLevel::Warning, status);
- }
-
- return result;
-}
-
auto BazelCasClient::UpdateSingleBlob(std::string const& instance_name,
ArtifactBlob const& blob) const noexcept
-> bool {
diff --git a/src/buildtool/execution_api/remote/bazel/bazel_cas_client.hpp b/src/buildtool/execution_api/remote/bazel/bazel_cas_client.hpp
index 3f83d712..f5e2267f 100644
--- a/src/buildtool/execution_api/remote/bazel/bazel_cas_client.hpp
+++ b/src/buildtool/execution_api/remote/bazel/bazel_cas_client.hpp
@@ -16,7 +16,6 @@
#define INCLUDED_SRC_BUILDTOOL_EXECUTION_API_REMOTE_BAZEL_BAZEL_CAS_CLIENT_HPP
#include <cstddef>
-#include <cstdint>
#include <functional>
#include <memory>
#include <optional>
@@ -80,12 +79,6 @@ class BazelCasClient {
std::unordered_set<ArtifactDigest> const& blobs) const noexcept
-> std::unordered_set<ArtifactBlob>;
- [[nodiscard]] auto GetTree(std::string const& instance_name,
- bazel_re::Digest const& root_digest,
- std::int32_t page_size,
- std::string const& page_token = "")
- const noexcept -> std::vector<bazel_re::Directory>;
-
/// \brief Upload single blob via bytestream
/// \param[in] instance_name Name of the CAS instance
/// \param[in] blob The blob to upload