This commit adds support for the following two JVM system properties
that control the Gradle build for alternative JDKs (i.e., a JDK other
than the one used to launch the Gradle process).
- customJavaHome: absolute path to the alternate JDK installation to
use to compile Java code and execute tests. Setting this system
property causes Groovy 3.0 RC3 to be used instead of 2.5.x. This
system property is also used in spring-oxm.gradle to determine
whether JiBX is supported.
- customJavaSourceVersion: Java version supplied to the `--release`
command line flag to control the Java source and target compatibility
version. Supported versions include 9 or higher. Do not set this
system property if Java 8 should be used.
Examples:
./gradlew -DcustomJavaHome=/opt/java/jdk-14 test
./gradlew --no-build-cache -DcustomJavaHome=/opt/java/jdk-14 test
./gradlew -DcustomJavaHome=/opt/java/jdk-14 -DcustomJavaSourceVersion=14 test
See gh-24474
Previously, anyone could publish a scan and publishing was performed
if the GRADLE_ENTERPRISE_URL environment variable was set.
ge.spring.io has now been locked down to prohibit anonymous build scan
publishing. This commit aligns with this change by only attempting to
publish a build scan when authenticated with the server.
Authentication is achieved via an access token that is made available
via an environment variable on CI and locally via a file in ~/.gradle.
One can obtain an access key by running the following command:
./gradlew provisionGradleEnterpriseAccessKey
Closes gh-24371
This commit updates the build to use the latest version of the
Asciidoctor Gradle Plugin. One significant new feature is that the
plugin's tasks are now cacheable.
Closes gh-24216