Skip to content

add sentinel-web-servlet-6x module and support springboot3.0. issue:#…#3001

Closed
LiYangSir wants to merge 1 commit into
alibaba:masterfrom
LiYangSir:web-servlet-springboot3.x
Closed

add sentinel-web-servlet-6x module and support springboot3.0. issue:#…#3001
LiYangSir wants to merge 1 commit into
alibaba:masterfrom
LiYangSir:web-servlet-springboot3.x

Conversation

@LiYangSir
Copy link
Copy Markdown
Contributor

…2998

Describe what this PR does / why we need it

Add sentinel-web-servlet-6x module, support springboot3.0

Does this pull request fix one issue?

Fixes: #2998

Describe how you did it

Replace javax.servlet-api dependency with jakarta.servlet-api. The package name uses jakarta to replace javax

Describe how to verify it

environment:springboot:3.0.0, JDK17

  1. create a new FilterBean and set the Filter to CommonFilter. CommonTotalFilter is the same
    @Bean
    public FilterRegistrationBean myFilter() {
        FilterRegistrationBean myFilter = new FilterRegistrationBean();
        myFilter.addUrlPatterns("/*");
        myFilter.setFilter(new CommonFilter());
        return myFilter;
    }
  1. create a HelloController to test
    @GetMapping("/hello")
    public String hello() {
        try (Entry entry = SphU.entry("hello")) {
            return "hello";
        } catch (BlockException e) {
            return "world";
        }
    }
  1. Check whether the cluster point link detects the cluster point and whether the corresponding rule takes effect

image

image

image

Special notes for reviews

None

@sczyh30 sczyh30 added the area/integrations Issues or PRs related to integrations with open-source components label Dec 15, 2022
Comment thread sentinel-adapter/sentinel-web-servlet-6x/pom.xml Outdated
Comment thread sentinel-adapter/sentinel-web-servlet-6x/pom.xml Outdated
@sczyh30 sczyh30 added the kind/feature Category issues or prs related to feature request. label Dec 16, 2022
@LiYangSir LiYangSir closed this by deleting the head repository Mar 22, 2023
@liwu96
Copy link
Copy Markdown

liwu96 commented Oct 31, 2023

为啥老哥关闭了这个呀?

@zhangdc007
Copy link
Copy Markdown

怎么close了,最新的1.8.8 还是不支持jakarta 啊,CommonFilter() 的file 还是javax的包,无法升级到spring boot 3.x

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

Labels

area/integrations Issues or PRs related to integrations with open-source components kind/feature Category issues or prs related to feature request.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for Jakarta EE Servlet in adapter modules

5 participants