根本原因就是 Spring-boot内置的tomcat 和你导入的javax.servlet-api起冲突
解决办法把javax.servlet-api去掉
<!-- <dependency>-->
<!-- <groupId>javax.servlet</groupId>-->
<!-- <artifactId>javax.servlet-api</artifactId>-->
<!-- </dependency>-->