Search in sources :

Example 1 with ApplicationFilterChain

use of org.apache.catalina.core.ApplicationFilterChain in project tomcat by apache.

the class Request method getNonAsyncClassNames.

private Set<String> getNonAsyncClassNames() {
    Set<String> result = new HashSet<>();
    Wrapper wrapper = getWrapper();
    if (!wrapper.isAsyncSupported()) {
        result.add(wrapper.getServletClass());
    }
    FilterChain filterChain = getFilterChain();
    if (filterChain instanceof ApplicationFilterChain) {
        ((ApplicationFilterChain) filterChain).findNonAsyncFilters(result);
    } else {
        result.add(sm.getString("coyoteRequest.filterAsyncSupportUnknown"));
    }
    Container c = wrapper;
    while (c != null) {
        c.getPipeline().findNonAsyncValves(result);
        c = c.getParent();
    }
    return result;
}
Also used : HttpServletRequestWrapper(jakarta.servlet.http.HttpServletRequestWrapper) Wrapper(org.apache.catalina.Wrapper) Container(org.apache.catalina.Container) ApplicationFilterChain(org.apache.catalina.core.ApplicationFilterChain) FilterChain(jakarta.servlet.FilterChain) ApplicationFilterChain(org.apache.catalina.core.ApplicationFilterChain) HashSet(java.util.HashSet)

Aggregations

FilterChain (jakarta.servlet.FilterChain)1 HttpServletRequestWrapper (jakarta.servlet.http.HttpServletRequestWrapper)1 HashSet (java.util.HashSet)1 Container (org.apache.catalina.Container)1 Wrapper (org.apache.catalina.Wrapper)1 ApplicationFilterChain (org.apache.catalina.core.ApplicationFilterChain)1