From d0e5637dbe2b4bdf0efa263f8c78e639a8d52ef8 Mon Sep 17 00:00:00 2001 From: Eric Burnett Date: Tue, 8 Mar 2022 10:58:01 -0500 Subject: [PATCH] Specify acceptable optimizations for input roots Clarify semantics for how files in the input root should appear to actions, and how implementations may deviate from this ideal for performance reasons. --- build/bazel/remote/execution/v2/remote_execution.proto | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/build/bazel/remote/execution/v2/remote_execution.proto b/build/bazel/remote/execution/v2/remote_execution.proto index 247d7741..e0e5bf21 100644 --- a/build/bazel/remote/execution/v2/remote_execution.proto +++ b/build/bazel/remote/execution/v2/remote_execution.proto @@ -465,6 +465,16 @@ message Action { // directory, as well as every subdirectory and content blob referred to, MUST // be in the // [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage]. + // + // Implementations SHOULD make it appear as if all files in the input root are + // actually present in the specified locations in the input filesystem, and are + // unique copies of the input blobs (unless otherwise specified in the Directory + // tree). However, for optimization reasons implementations MAY break this + // illusion in action-visible ways, e.g. by hardlinking input files to each + // other or to files outside the input root. This will result in certain actions + // not being runnable on those implementations, though for portability actions + // SHOULD avoid being strongly dependent on inode uniqueness, and be tolerant of + // different ways to back a given filesystem path. Digest input_root_digest = 2; reserved 3 to 5; // Used for fields moved to [Command][build.bazel.remote.execution.v2.Command].