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 Boot 3 support #768

Closed
sanyarnd opened this issue Apr 2, 2022 · 6 comments · Fixed by #826
Closed

Spring Boot 3 support #768

sanyarnd opened this issue Apr 2, 2022 · 6 comments · Fixed by #826

Comments

@sanyarnd
Copy link

sanyarnd commented Apr 2, 2022

Hi everything is working as expected, except these 3 imports: SB3 has migrated to jakarta namespace.

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

@whiskeysierra
Copy link
Collaborator

jakarta namespace

What does that mean exactly?

@sanyarnd
Copy link
Author

https://spring.io/blog/2022/05/24/preparing-for-spring-boot-3-0

Check if Third-party Projects Have Jakarta EE 9 Compatible Releases

Jakarta EE 9 a new top-level jakarta package, replacing EE 8’s javax top-level package. For example, the Servlet specification in Jakarta EE 8 uses a javax.servlet package but this has changed to jakarta.servlet in EE 9.

Generally speaking, it’s not possible to mix Java EE and Jakarta EE APIs in the same project. You need to ensure that your own code, as well as all third-party libraries are using jakarta.* package imports.

@norrs
Copy link

norrs commented Aug 16, 2022

I've been playing around with fixing spring boot 3x support here: main...norrs:problem-spring-web:springboot-3x - but currently have issues with ResponseStatusAdviceTraitTest (webflux) returning non-detailed exceptions. Ie it returns Failed to read HTTP message instead of string containing java.math.BigDecimal on ReponseStatusAdviceTraitTest.invalidFormat() . I suspect it could be related to https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-2.3-Release-Notes#changes-to-the-default-error-pages-content , but that's odd again since current main branch works with spring boot 2.6.4.

I also noticed it looks like spring framework 6.x (which is used by spring-boot 3.x) will come with batteries included according to spring-projects/spring-framework#27052 . Might have a peak and see how easy it is to replace it with how upstream plans to use "problem-json".

@PascalSchumacher
Copy link
Contributor

Spring Web API changed in 6 see #792, so this would also have to be adapted.

@cemo
Copy link
Contributor

cemo commented Dec 21, 2022

@cemo
Copy link
Contributor

cemo commented Dec 21, 2022

I opened a PR #826.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants