springboot 性能调试(SpringBoot2.0实战6配置Undertow服务器)
替换 SpringBoot 的启动服务器 Tomcat 服务器为 Undertow 服务器
操作步骤添加依赖
引入 Spring Boot Starter 父工程
在引入 spring-boot-starter-web 依赖时,剔除出对 tomcat 的依赖,然后再添加对 undertow 的依赖用于替换 tomcat。
验证结果
启动项目,查看启动日志,可以看到如下两行
源码地址
本章源码 : https://gitee.com/gongm_24/spring-boot-tutorial.git
总结Undertow 是一个比 Tomcat 性能更好的服务器,这是一个优化项。
,免责声明:本文仅代表文章作者的个人观点,与本站无关。其原创性、真实性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容文字的真实性、完整性和原创性本站不作任何保证或承诺,请读者仅作参考,并自行核实相关内容。文章投诉邮箱:anhduc.ph@yahoo.com