One of the Spring boot learning notes: The difference between a traditional MAVEN project and the use of the Spring boot project

Source: Internet
Author: User
Project Structure Differences

The project structure of the traditional Maven build is as follows:

The adoption Springboot project structure built with MAVEN is as follows:

The two structures are identical, the difference is as follows: traditional projects if you need to fight a war package, you need to configure the Web. xml file in the Web-inf directory structure; springboot does not need

Starting mode Difference

Traditional Web project start-up: Import the project into the Eclipse and Tomcat plug-in, then launch Tomcat and the project is started. Or make the project into a war package, put it in Tomcat, start Tomcat

Start with Springboot project: As shown in, open Helloworldapplication.java (this class each project has, class name custom), this is a class with the Main method, click the main method, right run As-java Application

Differences in configuration Files

The configuration files for both are placed under src/main/resources

Legacy Project: More profiles, must contain applicationcontext.xml this core profile

Using Springboot project: Less configuration files, compared to traditional projects, can say that the configuration file is very small, must contain application.properties (or application.yml) this configuration file

2018-05-19

One of the Spring boot learning notes: The difference between a traditional MAVEN project and the use of the Spring boot project

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.