feat: add Jakarta EE Servlet 6.0 adapter module (#2998)#3618
Conversation
|
I have read and fully agree to the Contributor License Agreement (CLA). |
|
The CLA check failed. Please ensure that your commit email matches your GitHub account email. |
|
@CLAassistant recheck please. I have signed the CLA. |
|
The tests failed on JDK 8 and 11. It is recommended to partially skip them by referencing other v6x components. For example, you can add the <skip.spring.v6x.test>false</skip.spring.v6x.test> configuration, similar to what is done in sentinel-spring-webmvc-v6x-adapter. |
|
@LearningGp Thanks for the feedback! I see two issues:
Will update the PR shortly. |
Add sentinel-web-servlet-jakarta module to support Jakarta EE Servlet
6.0 (Spring Boot 3.x, JDK 17+).
Changes:
- New module: sentinel-adapter/sentinel-web-servlet-jakarta
- All javax.servlet imports replaced with jakarta.servlet
- jakarta.servlet-api 6.0.0 (replacing javax.servlet-api 3.1.0)
- Spring Boot 3.2.0 for tests (replacing 1.5.17.RELEASE)
- Added new module to sentinel-adapter/pom.xml
Usage:
<dependency>
<groupId>com.alibaba.csp</groupId>
<artifactId>sentinel-web-servlet-jakarta</artifactId>
</dependency>
Fixes alibaba#2998
b61ce9c to
4d21d48
Compare
|
@LearningGp Thanks for the feedback!
I'll push the rebased commits shortly. |
|
@LearningGp Thanks for the review! Both issues have been addressed:
Please let me know if there are any other concerns! |
Fixes #2998
Summary
Add sentinel-web-servlet-jakarta module to support Jakarta EE Servlet 6.0 (Spring Boot 3.x, JDK 17+).
Background
Spring Boot 3.x migrated from javax.servlet to jakarta.servlet as part of the Jakarta EE 9+ transition. The existing sentinel-web-servlet module uses javax.servlet-api 3.1.0 and is incompatible with Spring Boot 3.x applications.
Previous PR #3001 attempted this but was closed without merge.
Changes
New module: sentinel-adapter/sentinel-web-servlet-jakarta
Modified: sentinel-adapter/pom.xml
Usage
com.alibaba.csp sentinel-web-servlet-jakartaCompatibility