Repository navigation
ci: fall back to Maven Central when the mirror lacks an artifact - #27619
vaadin-bot wants to merge 1 commit into
Conversation
Google's mirror of Maven Central syncs with a delay, so an artifact released minutes ago is not there yet. With the mirror configured as a <mirror> of central, Maven never asked Central itself and the build failed. Add the mirror as a repository in an active settings profile instead, so it is tried first and Maven falls back to the pom repositories and to Central on a 404. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
The The old mirror was kept under the id The
How I reproduced it, on this PR's commit with an empty local repository and
CI doesn't show this yet because the current cache was built when the mirror's id was Possible fixes:
Side note: Central is also asked for plugin version lists that the poms don't pin. Locally, |
…10902) (CP: 25.4) (#10907) This PR cherry-picks changes from the original PR #10902 to branch 25.4. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>
…10902) (CP: 24.7) (#10911) This PR cherry-picks changes from the original PR #10902 to branch 24.7. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>
…10902) (CP: 24.4) (#10912) This PR cherry-picks changes from the original PR #10902 to branch 24.4. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>
…10902) (CP: 24.9) (#10910) This PR cherry-picks changes from the original PR #10902 to branch 24.9. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>
…10902) (CP: 24.10) (#10909) This PR cherry-picks changes from the original PR #10902 to branch 24.10. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>
…10902) (CP: 25.3) (#10908) This PR cherry-picks changes from the original PR #10902 to branch 25.3. --- > ## Description > > Follow-up to #10886, which resolved Maven Central through Google's mirror by configuring the mirror as a `<mirror>` of `central`. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This happened in #10900: `com.vaadin:vaadin-testbench-shared:25.4.0-rc1` was on Central at 10:55 UTC, the run at 11:06 UTC failed with `Could not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/)`, and the mirror still answered 404 at about 11:30 UTC. > > - Replaced the `<mirror>` in `.github/maven/settings.xml` with a repository and plugin repository `google-maven-central` in an always-active settings profile > - Maven tries settings profile repositories first, then the pom repositories, and Central (from the super pom) last, so the mirror still serves almost everything and Central only gets the artifacts the mirror does not have yet > - Snapshots are disabled for the mirror so that snapshot lookups never go there > - Artifacts already in the cached `~/.m2/repository` under the id `central` stay valid, because `central` is still one of the repositories > - The workflows are unchanged, as they already pass the file with `-gs` > > Verified locally with Maven 3.9.5, an empty local repository and a pom that declares `vaadin-prereleases`: `vaadin-testbench-shared:25.4.0-rc1` was requested from `google-maven-central` (404), then `vaadin-prereleases` (404), then downloaded from `central`. Plugins were downloaded from `google-maven-central`, and a second run downloaded nothing. > > Same change in Flow: vaadin/flow#27619 > > ## Type of change > > - Internal change > > 🤖 Generated with [Claude Code](https://claude.com/claude-code) > Co-authored-by: Zhe Sun <zhe@vaadin.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Sascha Ißbrücker <sissbruecker@vaadin.com>



Description
Follow-up to #27418, which resolved Maven Central through Google's mirror by configuring the mirror as a
<mirror>ofcentral. Google syncs from Central with a delay, and a mirror replaces Central completely, so an artifact released minutes earlier fails to resolve. This hit flow-components (vaadin/flow-components#10900), which uses the same settings:com.vaadin:vaadin-testbench-shared:25.4.0-rc1was on Central at 10:55 UTC, the run at 11:06 UTC failed withCould not find artifact ... in central (https://maven-central.storage-download.googleapis.com/maven2/), and the mirror still answered 404 at about 11:30 UTC.central<mirror>in.github/maven/settings.xmlwith a repository and plugin repositorygoogle-maven-centralin an always-active settings profile~/.m2/repositoryunder the idcentralstay valid, becausecentralis still one of the repositories-gs.github/gradle/central-mirror.init.gradlestill replaces the Central URL with the mirror, so Gradle builds have the same weakness. It is not changed hereVerified locally with Maven 3.9.5, an empty local repository and a pom that declares
vaadin-prereleases:vaadin-testbench-shared:25.4.0-rc1was requested fromgoogle-maven-central(404), thenvaadin-prereleases(404), then downloaded fromcentral. Plugins were downloaded fromgoogle-maven-central, and a second run downloaded nothing.Same change in flow-components: vaadin/flow-components#10902
Type of change
🤖 Generated with Claude Code