How to add a RequestContextListener with no-xml configuration?

前端 未结 2 2008
清酒与你
清酒与你 2021-01-02 07:42

I need to add a listener to my Spring Boot application, in web.xml it looks like


 
    org.springframework.web.contex         


        
2条回答
  •  迷失自我
    2021-01-02 08:45

    I created this class and that solved my issue.

    @Configuration
    @WebListener
    public class MyRequestContextListener extends RequestContextListener {
    }
    

提交回复
热议问题