org.springframework.boot 2.2.1 version 下包含 tomcat 9.027 version
如果要在pom中升级tomcat到9.037版本,做如下修改
<tomcat-embed.version>9.0.37</tomcat-embed.version> <dependencyManagement> <dependencies> <dependency> <groupId>org.apache.tomcat.embed</groupId> <artifactId>tomcat-embed-core</artifactId> <version>${tomcat-embed.version}</version> </dependency> <dependency> <groupId>org.apache.tomcat.embed</groupId> <artifactId>tomcat-embed-el</artifactId> <version>${tomcat-embed.version}</version> </dependency> <dependency> <groupId>org.apache.tomcat.embed</groupId> <artifactId>tomcat-embed-websocket</artifactId> <version>${tomcat-embed.version}</version> </dependency> </dependencies>
建议使用 Maven Helper plugin for Idea 观看