package org.ta.pddserver.config;

import jakarta.servlet.*;
import jakarta.servlet.annotation.WebFilter;
import lombok.extern.slf4j.Slf4j;
import org.springframework.core.annotation.Order;

import java.io.IOException;

@WebFilter(
        urlPatterns = {"/open/*"}, filterName = "openFilter"
)
@Order(1)
@Slf4j
public class OpenFilter implements Filter {
    @Override
    public void init(FilterConfig filterConfig) throws ServletException {
        Filter.super.init(filterConfig);
        log.info("OPEN 过滤器初始化");
    }

    @Override
    public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain) throws IOException, ServletException {
        log.info("OPEN 开始处理请求，过滤数据");
    }


}
