From 85652e3b3fc6ae1f81435915976714c40088c576 Mon Sep 17 00:00:00 2001 From: Zack Winter <3457246+zackwintermdb@users.noreply.github.com> Date: Wed, 22 Apr 2026 08:59:00 -0700 Subject: [PATCH] SERVER-125021: Attempt Backing URL in 90% of Bazel Invocations Before Hitting Remote Asset API (#52328) GitOrigin-RevId: 564e715155028dc5c6229f1fa5b36bfb32288082 --- .bazeliskrc | 2 +- .bazelversion | 2 +- MODULE.bazel.lock | 4 ++-- tools/bazel | 10 ++++++++++ 4 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.bazeliskrc b/.bazeliskrc index e2a1d6510c8..2e3eac9992f 100644 --- a/.bazeliskrc +++ b/.bazeliskrc @@ -1 +1 @@ -BAZELISK_BASE_URL=https://mdb-build-public.s3.amazonaws.com/bazel_binary_waterfall_builds/06d753863dde251110daef739d2c3e419782b881 +BAZELISK_BASE_URL=https://mdb-build-public.s3.amazonaws.com/bazel_binary_waterfall_builds/90b8a7b661043fc7241aecddd17d39e75c8efd23 diff --git a/.bazelversion b/.bazelversion index 7c7672cb73d..958255a1151 100644 --- a/.bazelversion +++ b/.bazelversion @@ -1 +1 @@ -7.5.0-mongo_06d753863d \ No newline at end of file +7.5.0-mongo_90b8a7b661 \ No newline at end of file diff --git a/MODULE.bazel.lock b/MODULE.bazel.lock index c3bb24cc6d0..b99fe749029 100644 --- a/MODULE.bazel.lock +++ b/MODULE.bazel.lock @@ -537,7 +537,7 @@ }, "@@aspect_rules_js~//npm:extensions.bzl%pnpm": { "general": { - "bzlTransitiveDigest": "FM0lxNWZPFw5ktWotCCf2WsD2AHJDANeh2GFH57DP3U=", + "bzlTransitiveDigest": "ZiETCAm3yu6gU5QC0R5OrRO0ZS2lrnh7hm9Bd17t1As=", "usagesDigest": "nreWOSoW3keGlKdHpT5drUTOjHwIzGpp1haLECAZ4dM=", "recordedFileInputs": {}, "recordedDirentsInputs": {}, @@ -2002,7 +2002,7 @@ }, "@@rules_rust~//crate_universe/private:internal_extensions.bzl%cu_nr": { "general": { - "bzlTransitiveDigest": "HTx857xqjW5LFsaeJYKJhecWUKP9B57NYPrM1DCnnas=", + "bzlTransitiveDigest": "L9rxpG84287VYpuRM8hACDZ7jT04aXbaoJAQWk6Gf+Q=", "usagesDigest": "jdsFFevZIrOcSfuuZxyovS/wXbhPLIa/eBqyNOiTP98=", "recordedFileInputs": {}, "recordedDirentsInputs": {}, diff --git a/tools/bazel b/tools/bazel index eed696f33cb..66090efa18a 100755 --- a/tools/bazel +++ b/tools/bazel @@ -9,6 +9,16 @@ REPO_ROOT=$(dirname $(dirname $(realpath "$0"))) bazel_real="$BAZEL_REAL" +# 90% of the time, prefer downloading from the direct URL before trying the +# Remote Asset API (experimental_remote_downloader). This lets us benefit +# off of the added redundancy of the remote downloader while reducing traffic +# that's transmitted through the (expensive) ELB. +if [ -n "${CI:-}" ] && [ -z "${REVERSE_REMOTE_API_ATTEMPT_ORDER+x}" ]; then + if [ $(( RANDOM % 10 )) -ne 0 ]; then + export REVERSE_REMOTE_API_ATTEMPT_ORDER=1 + fi +fi + # If disk space becomes an issue, this block can be used to clean up configs