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

HHH-14315 Upgrade to Gradle 6.7 and use toolchains for per-JDK builds #3626

Merged
merged 4 commits into from Nov 10, 2020

Conversation

yrodiere
Copy link
Member

@yrodiere yrodiere commented Nov 9, 2020

https://hibernate.atlassian.net/browse/HHH-14315

After this PR, we will need a few change in our CI jobs, and then we will be able to test JDK16 (spoiler alert: it works).

This introduces similar changes to hibernate/hibernate-reactive#429.
By default, nothing changes, except that we now use Gradle 6.7.

When specific options are enabled:

  • We run Gradle with JDK8
  • We compile the project with JDK 8
  • We run the tests with a separate JVM version 11, 15 or 16.

Different configurations are also possible, e.g. run Gradle with JDK11, compile with JDK8 and run the tests with JDK15. But the one above is the most interesting and most likely the one we'll use.

@Sanne I think that, considering you need specific options to enable toolchains, we can safely backport to 5.4?

@yrodiere
Copy link
Member Author

yrodiere commented Nov 9, 2020

Signed-off-by: Yoann Rodière <yoann@hibernate.org>
Signed-off-by: Yoann Rodière <yoann@hibernate.org>
Apparently Gradle won't just use the same options as in its own JVM.

Signed-off-by: Yoann Rodière <yoann@hibernate.org>
For some reason the gradle build gets stuck at task
:hibernate-core:compileTestJava when using OpenJDK 11.0.3.
I can't reproduce the problem with 11.0.9, though, so it's probably a
bug in OpenJDK 11.0.3.

Signed-off-by: Yoann Rodière <yoann@hibernate.org>
settings.gradle Show resolved Hide resolved
@Sanne
Copy link
Member

Sanne commented Nov 10, 2020

Looks great! I'll merge it in master, but defer backporting it a bit. This might allow making some more changes in case there's need for CI setup?

@sebersole you might be interested? Much more flexibility and control of JDKs being used for build/release/testing.

@Sanne Sanne merged commit 2be511e into hibernate:master Nov 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants