Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mess around more with Javadoc and Maven toolchains: #7591

Merged
merged 1 commit into from
Jan 3, 2025

Conversation

copybara-service[bot]
Copy link
Contributor

Mess around more with Javadoc and Maven toolchains:

  • Use Temurin over Zulu. Per advice from @ben-manes, LTS versions of Temurin come pre-installed.
  • But be willing to run with any JDK of the appropriate version that's available, rather than requiring Zulu. (Not that this makes a huge difference, given that we'll still download Temurin JDKs. I didn't think this through much.)
  • Make the test jobs fail if they need to download a needed JDK because we didn't already put that one in place with setup-java. (Our other CI jobs, which publish snapshots to Sonatype and regenerate snapshot Javadoc, will continue to tolerate missing JDKs. We could change them, too, by making their scripts pass through options to identify the run as a CI run.) This should help us keep our versions in sync, and it should prevent us from silently falling back to slower downloads, per b/334979149.
  • Use Java 21 to generate Javadoc (as that's the best we can do now without further trouble). I've made sure to make it available through setup-java, including for generating Sonatype snapshots, which do include Javadoc. Plus, use Java 23 for the Maven VM itself there (so as to standardize on the same version as we already use for the Maven VM itself during our test workflows as of cl/711476575).
  • Fix a few Javadoc warnings, leaving behind only a handful that we can't easily do anything about.
  • Download Java 11 only when it is required. Currently, that's for JDiff and for our Gradle integration tests.

There is a decent change that this CL will break something, possibly not until we run the snapshot steps after submission... :)

RELNOTES=n/a

- Use Temurin over Zulu. Per [advice](#7492 (comment)) from @ben-manes, LTS versions of Temurin [come pre-installed](https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#Hosted-Tool-Cache).
- But be willing to run with any JDK of the appropriate version that's available, rather than requiring Zulu. (Not that this makes a huge difference, given that we'll still *download* Temurin JDKs. I didn't think this through much. I guess you can now at least avoiding downloading a Temurin JDK if you make sure you already have enough JDKs registered and you pass `-Dtoolchain.skip`.)
- Make the test jobs fail [if they need to download a needed JDK](https://github.com/linux-china/toolchains-maven-plugin#how-to-skip-toolchains-maven-plugin-on-cicd-platform) because we didn't already put that one in place with `setup-java`. (Our other CI jobs, which publish snapshots to Sonatype and regenerate snapshot Javadoc, will continue to tolerate missing JDKs. We could change them, too, by making their scripts pass through options to identify the run as a CI run.) This should help us keep our versions in sync, and it should prevent us from silently falling back to slower downloads, per b/334979149.
- Use Java 21 to generate Javadoc (as that's the best we can do now without [further trouble](#6790 (comment))). I've made sure to make Java 21 available through `setup-java`, including for generating Sonatype snapshots, which [do include Javadoc](https://oss.sonatype.org/content/repositories/snapshots/com/google/guava/guava/HEAD-jre-SNAPSHOT/). Plus, use Java 23 for the Maven VM itself there (so as to standardize on the same version as we already use for the Maven VM itself during our test workflows as of cl/711476575).
- Fix a few Javadoc warnings, leaving behind only [a handful that we can't easily do anything about](#6790 (comment)).
- Download Java 11 only when it is required. Currently, that's for JDiff and for our Gradle integration tests.

There is a decent chance that this CL will break something, possibly not until we run the snapshot steps after submission... :)

RELNOTES=n/a
PiperOrigin-RevId: 711746683
@copybara-service copybara-service bot merged commit c171b9c into master Jan 3, 2025
@copybara-service copybara-service bot deleted the test_711520051 branch January 3, 2025 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant