Steps to build MAVEN distributed development Project __ Distributed

Source: Internet
Author: User
Tags parent directory

The above is a basic dependency structure for distributed development projects, where parent is the total parent directory of the entire project structure, and other projects can depend on it for creation. The benefit of this development is ease of management and efficiency. For example, if you want to clear the cache, or Maven install project, only need to operate a parent project, the other projects will do a corresponding operation.
Here's a look at the steps to build your project:
Click New Project new--> other--> maven--> maven--> maven project.

Continue clicking next to enter the next step.




Select WebApp and click Next.




The group ID and artifact ID correspond to the domain name inversion and project engineering name respectively.





When the new is finished, follow the image above. Then build the subproject of the parent project.

Right-click on the parent item new--> Other-->maven module

Select module, click Next, and go to the next step.




It is only necessary to fill in the project name on the line, and the project will automatically depend on the parent project.



View Pom.xml found in the configuration file, the parent project's coordinate information is automatically introduced. (My parent project here is manager.) )



A simple distributed project built on a parent project is built, and a more complete project structure typically has service, DAO, and Web, which can often be managed using the manager project to manage service, DAO, and the Web, leaving the manager dependent on parent. Convenient for better management.



A very good advantage of distributed build based projects is that you can manage jars uniformly, for example, we can centrally define some common dependency jar packages in the pom file of the Paren total parent project.


In this way, you can use these jar packages as long as the child projects that inherit from the parent project are available. Without having to reconfigure it again.
When the project is started, you can start the Web project and access the Web project directly.
————————————————————————————————————
In the process of building the whole distributed project, the big problem is basically not encountered, the directory structure settings and some jar package import, many are from the previous development project experience, and some templates. A large part of it is a direct reference. The project is a SSM framework, there are many ways to build, no matter whether or not to change the way changes in a few, the fundamental still lies in the new thing, new technology to explore constantly.




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.