Skip to content

[9.1.0] Migrate from URL to URI#28802

Merged
meteorcloudy merged 3 commits intobazelbuild:release-9.1.0from
iancha1992:cp28664_2
Feb 27, 2026
Merged

[9.1.0] Migrate from URL to URI#28802
meteorcloudy merged 3 commits intobazelbuild:release-9.1.0from
iancha1992:cp28664_2

Conversation

@iancha1992
Copy link
Copy Markdown
Member

The URL class is a legacy concept and a performance footgun as its equals/hashCode methods call out to the network. This affected the event subscriber CacheHitReportingModule, which stored URLs in a Set and thus triggered DNS resolution, even if all downloads hit the cache.

While most of this change is not expected to cause any change in behavior, it has to fix a regression introduced by 8cefb8b: As of that commit, user info has no longer been forwarded to the new location requested by a redirect if the host and port stay the same. This was masked by insufficient test cases that relied on URL#equals, which ignores user info.

Work towards #25068

Closes #28661.

PiperOrigin-RevId: 871745758
Change-Id: Ib4783d28ac155315a7bcf309645118ec02ff783d

Commit 5594c2a, 63f32ce, eded4bb

Ashutosh0x and others added 3 commits February 25, 2026 11:51
…ld#28347)

When a mirror URL fails with an SSLException (e.g. expired certificate), the downloader should fail over to the next mirror immediately instead of retrying the failing URL multiple times.

Fixes bazelbuild#28158

RELNOTES: Bazel now fails over immediately to mirror URLs if a TLS handshake error occurs.

CC @lberki @fmeum @Wyv

Closes bazelbuild#28347.

PiperOrigin-RevId: 861936486
Change-Id: If40b966224c1e0687dd258adb2c03bbf055b8c40
You can now set the `--downloader_config` flag multiple times to specify several downloader config files at once.

Fixes bazelbuild#13131

---

An initial refactoring was done to clean up unused arguments in `UrlRewriter`.

Closes bazelbuild#27877.

PiperOrigin-RevId: 842125029
Change-Id: Ic851d9dd7e0e2505125459d7fda5a32946cec263
The `URL` class is a legacy concept and a performance footgun as its `equals`/`hashCode` methods call out to the network. This affected the event subscriber `CacheHitReportingModule`, which stored `URL`s in a Set and thus triggered DNS resolution, even if all downloads hit the cache.

While most of this change is not expected to cause any change in behavior, it has to fix a regression introduced by 8cefb8b: As of that commit, user info has no longer been forwarded to the new location requested by a redirect if the host and port stay the same. This was masked by insufficient test cases that relied on `URL#equals`, which ignores user info.

Work towards bazelbuild#25068

Closes bazelbuild#28661.

PiperOrigin-RevId: 871745758
Change-Id: Ib4783d28ac155315a7bcf309645118ec02ff783d
@iancha1992 iancha1992 added awaiting-review PR is awaiting review from an assigned reviewer team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. labels Feb 25, 2026
@meteorcloudy
Copy link
Copy Markdown
Member

This is still draft?

@meteorcloudy meteorcloudy marked this pull request as ready for review February 27, 2026 10:37
@meteorcloudy meteorcloudy requested a review from a team as a code owner February 27, 2026 10:37
@meteorcloudy meteorcloudy added this pull request to the merge queue Feb 27, 2026
@github-actions github-actions Bot added the team-Remote-Exec Issues and PRs for the Execution (Remote) team label Feb 27, 2026
Merged via the queue into bazelbuild:release-9.1.0 with commit f60e626 Feb 27, 2026
47 checks passed
@github-actions github-actions Bot removed the awaiting-review PR is awaiting review from an assigned reviewer label Feb 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. team-Remote-Exec Issues and PRs for the Execution (Remote) team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants