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

TCK compilation error in JDK 17.0.2 #1250

Open
alwin-joseph opened this issue Mar 29, 2024 · 3 comments
Open

TCK compilation error in JDK 17.0.2 #1250

alwin-joseph opened this issue Mar 29, 2024 · 3 comments
Milestone

Comments

@alwin-joseph
Copy link
Contributor

TCK compilation error happening in JDK17 with the current main branch as run in https://ci.eclipse.org/rest/job/TCK_EFTL_build_and_stage/6/.

The TCK build passes with JDK21 with latest changes https://ci.eclipse.org/rest/job/TCK_EFTL_build_and_stage/7/.

The 2 types of issues are as below:

non-varargs call of varargs method with inexact argument type for last parameter;
[ERROR]   cast to java.lang.Object for a varargs call
[ERROR]   cast to java.lang.Object[] for a non-varargs call and to suppress this warning.

This can be resolved by an Object cast as JaxrsUtil.iterableToString(";", (Object) headers)) in below files:
jaxrs-tck/src/main/java/ee/jakarta/tck/ws/rs/ee/rs/beanparam/BeanParamCommonClient.java
jaxrs-tck/src/main/java/ee/jakarta/tck/ws/rs/ee/rs/cookieparam/JAXRSClientIT.java.

Errors like below which also appeared as warnings first.

APPLICATION_SVG_XML in jakarta.ws.rs.core.MediaType has been deprecated and marked for removal
APPLICATION_SVG_XML_TYPE in jakarta.ws.rs.core.MediaType has been deprecated and marked for removal
Integer(int) in java.lang.Integer has been deprecated and marked for removal

after an error message : java.lang.NullPointerException: Cannot invoke "com.sun.tools.javac.code.Type.getThrownTypes()" because "tree.meth.type" is null

It looks like the issue is with JDK17.0.2 version which is also the Java 17 version used in Jenkins .
Locally the build passed when JDK 17.0.10 was used as it was suggested by James.

Apparently there seems to be no other JDK17 version available in Jenkins to resolve the build issue.

@spericas spericas added this to the 4.0 milestone Mar 29, 2024
@alwin-joseph
Copy link
Contributor Author

Created gitlab issue https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/issues/4484 to provide openjdk-jdk17.0.9 or openjdk-jdk17.0.10 as latest JDK in the Jenkins ci.eclipse.org/rest

@alwin-joseph
Copy link
Contributor Author

temurin-jdk17-latest points to 17.0.9+9 as mentioned by the Eclipse infra team. WIll be using the same in Jenkins job to build the TCK.

@jamezp
Copy link
Contributor

jamezp commented Mar 29, 2024

Thank you for looking into this @alwin-joseph!

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

No branches or pull requests

3 participants