首页 > 编程语言 > 详细

springboot整理

时间:2020-04-30 13:11:53      阅读:48      评论:0      收藏:0      [点我收藏+]

idea切换项目:

https://jingyan.baidu.com/article/624e7459008f4234e8ba5a97.html

 

Spring Boot2.0以上版本EmbeddedServletContainerCustomizer被WebServerFactoryCustomizer替代

 

在Spring Boot2.0以上配置嵌入式Servlet容器时EmbeddedServletContainerCustomizer类不存在,经网络查询发现被WebServerFactoryCustomizer替代

 

https://blog.csdn.net/Hard__ball/article/details/81281898?utm_source=blogxgwz4

 

注册三大组件之listener方法:

 @Bean
    public ServletListenerRegistrationBean<Mylistener> mylistener(){
        ServletListenerRegistrationBean<Mylistener> servletListenerRegistrationBean=new ServletListenerRegistrationBean<>();
        servletListenerRegistrationBean.setListener(new Mylistener());
        return  servletListenerRegistrationBean;
    }

idea快捷键

https://jingyan.baidu.com/article/ed15cb1b86dab21be3698184.html

 

springboot整理

原文:https://www.cnblogs.com/www1842564021/p/12808124.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!