From 8ce2c82a95d32ec98990d65184a16f6ff77907c6 Mon Sep 17 00:00:00 2001 From: Son Luong Ngoc Date: Fri, 26 Jul 2024 16:11:33 +0200 Subject: [PATCH] RemoteOptions: flip remote_use_output_paths --- .../lib/remote/options/RemoteOptions.java | 4 ++-- .../bazel/remote/remote_execution_test.sh | 18 ++++++++---------- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/src/main/java/com/google/devtools/build/lib/remote/options/RemoteOptions.java b/src/main/java/com/google/devtools/build/lib/remote/options/RemoteOptions.java index a8cf8350e5b6af..be39e3a1de5b30 100644 --- a/src/main/java/com/google/devtools/build/lib/remote/options/RemoteOptions.java +++ b/src/main/java/com/google/devtools/build/lib/remote/options/RemoteOptions.java @@ -415,12 +415,12 @@ public RemoteBuildEventUploadModeConverter() { @Option( name = "incompatible_remote_use_output_paths", - defaultValue = "false", + defaultValue = "true", documentationCategory = OptionDocumentationCategory.REMOTE, effectTags = {OptionEffectTag.UNKNOWN}, help = "If enabled, check if the remote server(s) support remote execution API v2.1 or newer." - + "If yes, use the newer Command.output_paths field. Default is false.") + + "If yes, use the newer Command.output_paths field. Default is true.") public boolean useOutputPaths; @Option( diff --git a/src/test/shell/bazel/remote/remote_execution_test.sh b/src/test/shell/bazel/remote/remote_execution_test.sh index bd8264b48dfe50..5f15c7fbb1ccb8 100755 --- a/src/test/shell/bazel/remote/remote_execution_test.sh +++ b/src/test/shell/bazel/remote/remote_execution_test.sh @@ -47,7 +47,7 @@ source "$(rlocation "io_bazel/src/test/shell/bazel/remote/remote_utils.sh")" \ || { echo "remote_utils.sh not found!" >&2; exit 1; } function set_up() { - start_worker --legacy_api + start_worker } function tear_down() { @@ -91,7 +91,7 @@ function setup_credential_helper_test() { EOF stop_worker - start_worker --legacy_api --expected_authorization_token=TOKEN + start_worker --expected_authorization_token=TOKEN } function test_credential_helper_remote_cache() { @@ -179,10 +179,9 @@ function test_credential_helper_clear_cache() { } function test_remote_grpc_cache_with_legacy_api() { - # TODO(sluongng): Add this when we flip the default to use Remote API version 2.1. # Test if Bazel works with Remote Cache using Remote Api version 2.0. - # stop_worker - # start_worker --legacy_api + stop_worker + start_worker --legacy_api mkdir -p a cat > a/BUILD < a/BUILD <