Skip to content

Commit

Permalink
Add the ability to control which files in the input root are hardlinked
Browse files Browse the repository at this point in the history
This change acts as a counter proposal to PR #216. Instead of globally
stating whether files should be hardlinked or not, it adds the ability
to let clients control whether files are aliased.

It achieves this by adding a salt field to FileNode. If two files have
the same salt and all other (non-name) properties match, they SHOULD get
constructed in the form of hardlinks.
  • Loading branch information
EdSchouten committed Apr 12, 2022
1 parent 9e72daf commit 2ff088a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions build/bazel/remote/execution/v2/remote_execution.proto
Original file line number Diff line number Diff line change
Expand Up @@ -779,6 +779,14 @@ message FileNode {
// The node properties of the FileNode.
reserved 5;
NodeProperties node_properties = 6;

// Salt to force that files in the input root have distinct inode
// numbers, even if all properties match.
//
// Two files with in the input root SHOULD have the same inode number
// iff they have the same digest, is_executable flag, node_properties,
// and hardlink_salt.
bytes hardlink_salt = 7;
}

// A `DirectoryNode` represents a child of a
Expand Down

0 comments on commit 2ff088a

Please sign in to comment.