Skip to content

java: use GCS mirror for Maven, other small changes#992

Merged
rapids-bot[bot] merged 2 commits into
rapidsai:mainfrom
jameslamb:fix/java-builds
Jun 24, 2026
Merged

java: use GCS mirror for Maven, other small changes#992
rapids-bot[bot] merged 2 commits into
rapidsai:mainfrom
jameslamb:fix/java-builds

Conversation

@jameslamb

Copy link
Copy Markdown
Member

Contributes to rapidsai/build-planning#297

RAPIDS projects using NVIDIA-hosted GitHub Actions runners have been getting rate-limited by Maven Central. Similar to NVIDIA/cuvs#2253, this proposes fixing that by using the same read-only Maven mirror that Apache Orc, Lucene, Spark and others use in their builds (https://storage-download.googleapis.com/maven-central/index.html).

Other changes:

  • adding default mvn options to request packages more slowly and wait longer between retries
  • updating RAPIDS pre-commit hooks
  • adding check-xml hook to validate that pom.xml are valid XML docs
  • reformatting READMEs per https://yihui.org/en/2021/06/markdown-breath/
  • other minor pom.xml maintenance (see comments)

@jameslamb jameslamb added improvement Improves an existing functionality non-breaking Introduces a non-breaking change labels Jun 24, 2026
@copy-pr-bot

copy-pr-bot Bot commented Jun 24, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@jameslamb

Copy link
Copy Markdown
Member Author

/ok to test

Comment thread java/.mvn/maven.config
-Daether.connector.basic.downstreamThreads=1
-Daether.transport.http.retryHandler.count=5
-Daether.transport.http.retryHandler.interval=10000
-Dmaven.wagon.http.retryHandler.count=5

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See NVIDIA/cuvs#2253 (comment) for an explanation of these flags.

I believe comments are not allowed in this file because its contents are passed literally to mvn.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if it's worth a CI re-run, but one option (maybe) would be to document the options in a README inside the .mvn directory. But that shouldn't block this.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah fair. I went back and forth on that and settled on not doing it because I thought the git blame pointing back to this PR + the mostly informative names was probably enough to communicate the intent.

I'm gonna treat that "I don't know" and "(maybe)" as you also being unsure about how to handle this 😂

Think I'll just merge it as-is.

Comment thread java/pom.xml
<version>3.1.0</version>
<configuration>
<createDirs>true</createDirs>
</configuration>

@jameslamb jameslamb Jun 24, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

createDirs is not a valid property for maven-clean-plugin: https://github.com/search?q=repo%3Aapache%2Fmaven-clean-plugin%20%22createDirs%22&type=code

Comment thread java/pom.xml
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>5.4.2</version>
<version>${junit.version}</version>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This version is stored a few lines up:

<junit.version>5.4.2</junit.version>

Reusing that value reduces the risk of inconsistencies.

Comment thread java/pom.xml
<plugin>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>3.0.0</version>
</plugin>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These don't have entries in <plugins> so don't need entries in <pluginManagement>.

@jameslamb jameslamb changed the title WIP: java: use GCS mirror for Maven, other small changes java: use GCS mirror for Maven, other small changes Jun 24, 2026
@jameslamb jameslamb marked this pull request as ready for review June 24, 2026 17:53
@jameslamb jameslamb requested a review from a team as a code owner June 24, 2026 17:53
@jameslamb jameslamb requested a review from gforsyth June 24, 2026 17:53

@gforsyth gforsyth left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just the one thought, but looks good. Thanks @jameslamb !

Comment thread java/.mvn/maven.config
-Daether.connector.basic.downstreamThreads=1
-Daether.transport.http.retryHandler.count=5
-Daether.transport.http.retryHandler.interval=10000
-Dmaven.wagon.http.retryHandler.count=5

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if it's worth a CI re-run, but one option (maybe) would be to document the options in a README inside the .mvn directory. But that shouldn't block this.

@jameslamb

Copy link
Copy Markdown
Member Author

/merge

@rapids-bot rapids-bot Bot merged commit 6d7c7e4 into rapidsai:main Jun 24, 2026
58 checks passed
@jameslamb jameslamb deleted the fix/java-builds branch June 24, 2026 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improvement Improves an existing functionality non-breaking Introduces a non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants