From d83c997ad5a866f4fbb38d4a81e7edf70a491db2 Mon Sep 17 00:00:00 2001 From: Sascha Roloff Date: Fri, 23 Feb 2024 09:32:54 +0100 Subject: Refactor split and splice implementations. Currently, the implementations of the split and splice operation are both hidden behind the Bazel API implementation. This was sufficient to implement splitting at the server and splicing at the client. In order to support the other direction of splitting at the client and splicing at the server while reusing their implementations, the code needs to be refactored. First, the functionality of split and splice are explicitly exposed at the general execution API interface and implemented in the sub APIs. Second, the implementations of split and splice are factored into a separate utils class. --- .../execution_api/execution_service/TARGETS | 30 +++++++++++++++++----- 1 file changed, 24 insertions(+), 6 deletions(-) (limited to 'src/buildtool/execution_api/execution_service/TARGETS') diff --git a/src/buildtool/execution_api/execution_service/TARGETS b/src/buildtool/execution_api/execution_service/TARGETS index 85068f0f..e494711c 100644 --- a/src/buildtool/execution_api/execution_service/TARGETS +++ b/src/buildtool/execution_api/execution_service/TARGETS @@ -58,12 +58,7 @@ , ["@", "fmt", "", "fmt"] , ["src/buildtool/storage", "storage"] , ["src/utils/cpp", "verify_hash"] - , ["src/buildtool/common", "common"] - , ["src/buildtool/file_system", "git_repo"] - , ["src/buildtool/file_system", "object_type"] - , ["src/buildtool/logging", "log_level"] - , ["src/utils/cpp", "hex_string"] - , "file_chunker" + , "cas_utils" ] } , "server_implementation": @@ -151,4 +146,27 @@ , "stage": ["src", "buildtool", "execution_api", "execution_service"] , "private-deps": [["@", "gsl", "", "gsl"]] } +, "cas_utils": + { "type": ["@", "rules", "CC", "library"] + , "name": ["cas_utils"] + , "hdrs": ["cas_utils.hpp"] + , "srcs": ["cas_utils.cpp"] + , "stage": ["src", "buildtool", "execution_api", "execution_service"] + , "deps": + [ ["@", "grpc", "", "grpc++"] + , ["src/buildtool/common", "bazel_types"] + , ["src/buildtool/storage", "storage"] + ] + , "private-deps": + [ "file_chunker" + , ["@", "fmt", "", "fmt"] + , ["src/buildtool/common", "common"] + , ["src/buildtool/compatibility", "compatibility"] + , ["src/buildtool/file_system", "git_repo"] + , ["src/buildtool/file_system", "object_type"] + , ["src/buildtool/file_system", "file_system_manager"] + , ["src/buildtool/storage", "fs_utils"] + , ["src/utils/cpp", "hex_string"] + ] + } } -- cgit v1.2.3