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

Spring 6 module introduction #5023

Merged
merged 1 commit into from
Apr 29, 2022
Merged

Spring 6 module introduction #5023

merged 1 commit into from
Apr 29, 2022

Conversation

jansupol
Copy link
Contributor

@jansupol jansupol commented Apr 1, 2022

Signed-off-by: jansupol jan.supol@oracle.com

@jansupol jansupol force-pushed the spring6 branch 5 times, most recently from 189a9e1 to 34a869b Compare April 2, 2022 08:43
@jansupol jansupol linked an issue Apr 2, 2022 that may be closed by this pull request
@wilkinsona
Copy link

wilkinsona commented Apr 4, 2022

Thanks, @jansupol. I've been trying to get Spring Boot working against a local build of your branch. One thing that tripped me up was the javaPre17 variant of SpringComponentProvider was being used instead of the java17 variant. As a result any Spring-managed beans were not available to Jersey as they should be. I think this was because I ran my local build (mvn -DskipTests=true clean install) with Java 8. Running it again with Java 17 resulted in a failure:

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  47.955 s
[INFO] Finished at: 2022-04-04T21:18:19+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project jersey-media-sse: Compilation failure: Compilation failure: 
[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[34,44] cannot find symbol
[ERROR]   symbol:   class JerseyFlowSubscriber
[ERROR]   location: package org.glassfish.jersey.internal.jsr166
[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[48,45] cannot find symbol
[ERROR]   symbol: class JerseyFlowSubscriber
[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[60,5] method does not override or implement a method from a supertype
[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[79,5] method does not override or implement a method from a supertype
[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[105,5] method does not override or implement a method from a supertype
[ERROR] -> [Help 1]

I then tried just building the spring6 module (mvn -f ext/spring6 -DskipTests=true clean install) and that seems to have fixed the problem. I suspect this is user error in how I built the project, but wanted to mention it just in case.

@jansupol
Copy link
Contributor Author

jansupol commented Apr 5, 2022

[ERROR] /Users/awilkinson/dev/eclipse-ee4j/jersey/media/sse/src/main/java/org/glassfish/jersey/media/sse/internal/JerseyEventSink.java:[48,45] cannot find symbol
[ERROR] symbol: class JerseyFlowSubscriber

Yes, I have seen this issue. The solution is to rebuild the core-common module.

Spring 6 does require JDK 17, that's why the javaPre17 classes.

@wilkinsona
Copy link

wilkinsona commented Apr 6, 2022

Thanks again, @jansupol. Once I had got the Jersey snapshot built correctly, I was able to get a clean build of Spring Boot with its Jersey support reinstated. The changes proposed here look good to me.

@jansupol
Copy link
Contributor Author

jansupol commented Apr 7, 2022

@jansupol
Copy link
Contributor Author

The CQs are resolved.

Signed-off-by: jansupol <jan.supol@oracle.com>
Copy link
Contributor

@senivam senivam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@senivam senivam merged commit c66ef81 into eclipse-ee4j:3.x Apr 29, 2022
@senivam senivam added this to the 3.1.0 milestone Apr 29, 2022
@wilkinsona
Copy link

@jansupol Spring Framework 6 and Spring Boot 3 will have a Jakarta EE 9 (JAX-RS 3.0) baseline. Would it be possible for the new jersey-spring6 module to be included in a Jersey release that supports JAX-RS 3.0?

@jansupol jansupol deleted the spring6 branch May 11, 2022 19:38
@jansupol
Copy link
Contributor Author

@wilkinsona Yes. Jersey 3.0.5 is planned to contain the module. We plan the release at the end of this month.

@jansupol jansupol modified the milestones: 3.1.0, 3.0.5 May 11, 2022
@wilkinsona
Copy link

That's great. Thanks very much once again.

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.

Support for Spring Framework 6
3 participants