From 432fd50358cfb7d90ca98bbf702d4909b30f74e8 Mon Sep 17 00:00:00 2001 From: Maksim Denisov Date: Tue, 21 Jan 2025 11:39:34 +0100 Subject: Call serve directly instead of EnsureAbsentRootOnServe. --- src/other_tools/root_maps/distdir_git_map.cpp | 26 ++++---------------------- 1 file changed, 4 insertions(+), 22 deletions(-) (limited to 'src/other_tools/root_maps/distdir_git_map.cpp') diff --git a/src/other_tools/root_maps/distdir_git_map.cpp b/src/other_tools/root_maps/distdir_git_map.cpp index 422a89cd..49329908 100644 --- a/src/other_tools/root_maps/distdir_git_map.cpp +++ b/src/other_tools/root_maps/distdir_git_map.cpp @@ -417,17 +417,8 @@ auto CreateDistdirGitMap( // remote CAS if (digest and remote_api->IsAvailable({*digest})) { // tell serve to set up the root from the remote CAS - // tree; upload can be skipped - if (EnsureAbsentRootOnServe( - *serve, - tree_id, - /*repo_path=*/"", - native_storage_config, - /*compat_storage_config=*/nullptr, - /*local_api=*/nullptr, - /*remote_api=*/nullptr, - logger, - /*no_sync_is_fatal=*/true)) { + // tree + if (serve->GetTreeFromRemote(*digest)) { // set workspace root as absent (*setter)(std::pair( nlohmann::json::array( @@ -457,17 +448,8 @@ auto CreateDistdirGitMap( return; } // tell serve to set up the root from the remote CAS - // tree; upload can be skipped - if (EnsureAbsentRootOnServe( - *serve, - tree_id, - /*repo_path=*/"", - native_storage_config, - /*compat_storage_config=*/nullptr, - /*local_api=*/nullptr, - /*remote_api=*/nullptr, - logger, - /*no_sync_is_fatal=*/true)) { + // tree + if (serve->GetTreeFromRemote(*digest)) { // set workspace root as absent (*setter)(std::pair( nlohmann::json::array( -- cgit v1.2.3