-
Notifications
You must be signed in to change notification settings - Fork 54
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
ci: upgrade Tycho to 3.0 #399
Conversation
@rnveach Maybe I could need some help with the Travis configuration for this one later. Tycho 3.0 needs Java 17, even though it can compile and test against Java 8, 11 and 17. I know how to configure this correctly locally, by using a JAVA_HOME pointing to 17 for execution of Tycho and having an /.m2/toolchains.xml pointing to the Java 11 JDK needed for compilation/test. Can the Travis configuration be tweaked similarly? Right now a single JDK is used both for the Maven execution and for the compilation inside, right? |
This is correct as seen at the following locations:
I found travis-ci/travis-cookbooks#35 (comment) when googling. I am not sure how possible this will be. I would also be very hesitant on setting up a complex CI run. It is always a pain getting things just right and the littlest thing break everything. Setting the java version in the POM should ensure we compile backwards for Java 11, but this means no one can compile this project without Java 17 as tycho run is required every maven run. You also have to remember everyone (old and new) will need to set up their local in a similar way otherwise they can't run development. What is even the benefit of having a newer Tycho? As it is right now, I am against such a complex change and we should stick to the highest version of tycho that supports Java 11 for now. |
I'm fine with staying on 11, if that leads to complicated CI setups. Honestly, I thought every Java developer has 17 on the local machine meanwhile, so at least that should not be an issue. :) There is no immediate benefit from using Tycho 3.0, except of "update dependencies as often as possible" to find new problems early. I'll port the warnings fix into a separate change then. |
Better to stay on jdk11. If we want be prepared for jdk17, we can make extra CI execution of |
35cea74
to
cf56087
Compare
cf56087
to
30455e3
Compare
That is the most recent version of Tycho. It requires Java 17 for running, but can compile Java 11 code. One of the plugins has been moved from tycho.extras to tycho core, therefore the groupid is different. Some new tycho plugins have been added. Even though we don't use them, they need to be configured due to our strict enforcer checks. There are new warnings at the very end of the build like `No digest algorithm is available to verify download`. That's an open issue in Tycho but it doesn't break the build, see eclipse-tycho/tycho#1482 Finally the target platform also needs to be updated. Tycho 3.0 resolves the JUnit classpath container of the .classpath files against the bundle names introduced in Eclipse 2022-06. Most thirdparty libraries have been changed from repackaging in Eclipse Orbit to "consume as is" from Maven. This does not affect the EclipseCS plugin created by the build, since the new JUnit bundles are only needed at IDE or build time. The jgit exception at the end of a Maven build can be ignored. It's fixed already upstream, but will probably only be available for use in Tycho with the Eclipse 2024-03 release.
30455e3
to
5dde2dd
Compare
Reviewers, please be aware that this PR has changed a lot since it started. It's now about Tycho 4 instead of 3 and it deals fine with the Java 11 and 17 mix. This is the current commit message: That is the most recent version of Tycho. It requires Java 17 for One of the plugins has been moved from tycho.extras to tycho core, There are new warnings at the very end of the build like Finally the target platform also needs to be updated. Tycho 3.0 resolves The jgit exception at the end of a Maven build can be ignored. It's |
@rnveach Do you want to give this a second look? The matrix configuration of the github workflow is not an issue anymore, since I install both 11 and 17 in every run. Also requiring Java 17 on the developer machine is a non-issue now, the Eclipse IDE also requires it meanwhile. |
That is the most recent version as of today. One of the plugins has been moved from tycho.extras to tycho core, therefore the groupid is different.
Also fix the warnings
[WARNING] artifact foo:bar:p2metadata:10.3.3-SNAPSHOT already attached, replace previous instance
by disabling the default metadata generation. Unfortunately this extra step is necessary when creating source features, since the attaching of metadata needs to be delayed then.There are new warnings at the very end of the build like
No digest algorithm is available to verify download
. That's an open issue in Tycho but it doesn't break the build, seeeclipse-tycho/tycho#1482
Finally the target platform also needs to be updated. Tycho 3.0 resolves the JUnit classpath container of the .classpath files against the bundle names introduced in Eclipse 2022-06. Most thirdparty libraries have been changed from repackaging in Eclipse Orbit to "consume as is" from Maven. This does not affect the EclipseCS plugin created by the build, since the new JUnit bundles are only needed at IDE or build time.