Spring boot is really a lot easier to develop, the spring boot contains spring MVC, the built-in Tomcat, and the main method to start
1. Create a new spring boot project using idea
File----New One project Select Spring Initializr and Next
The bottom is pom.xml.
<?xml version= "1.0" encoding= "UTF-8"? ><project xmlns= "http://maven.apache.org/POM/4.0.0" xmlns:xsi= "http ://www.w3.org/2001/XMLSchema-instance "xsi:schemalocation= "http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" > <modelversion>4.0.0 </modelVersion> <groupId>com.example</groupId> <artifactId>demo</artifactId> <ve Rsion>0.0.1-snapshot</version> <packaging>jar</packaging> <name>demo</name> < Description>demo Project for Spring boot</description> <parent> <groupId>org.springframework.boot</groupId> & Lt;artifactid>spring-boot-starter-parent</artifactid> <version>2.0.3.RELEASE</version> <relativePath/> <!--lookup parent from repository to </parent> <properties> <pro Ject.build.sourceencoding>utf-8</project.build.sourceencoding> <project.reporting.outputencoding >UTF-8</project.reporting.outputEncoding> <java.version>1.8</java.version> </properties& Gt <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactid>spring-boot-starter-test</ar Tifactid><scope>test</scope> </dependency> <!--tomcat support .--> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-tomcat< /artifactid> <scope>provided</scope> </dependency> <dependency> <groupId>org.apache.tomcat.embed</groupId> <artifactid>tomcat-embed-jasper</artifacti D> <scope>provided</scope> </dependency> <!--MySQL Drive-<d Ependency> <groupId>mysql</groupId> <artifactid>mysql-connector-java</artifa ctid> <version>5.1.21</version> </dependency> <dependency> <groupId>com.alibaba</groupId> <artifactId>druid</artifactId> <version> ;1.1.9</version> </dependency> <dependency> <groupId>org.mybatis.spring.boot</groupId> <artifactId>mybatis-spring-boot-starter</artifactId> <version>1.3.2</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactid>spring-boot-maven-plugin </artifactId> </plugin> </plugins> </build></project>
IDEA integrates spring boot JSP mybatis