How to understand the problems encountered in using idea to install multi-module projects
How to understand the problems encountered in the install of multi-module projects using idea, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can get something.
Time record
It is 11:27 in the evening of August 22nd, 2019.
Problems arise
With the dark horse programmer on the product purchase project development, when the pinyougou-servergoods-interface maven install, there is an install failure. The specific exceptions are as follows:
1. 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing.
[WARNING] [WARNING] Some problems were encountered while building the effective model for com.xxx.xxx:xxxx:jar:0.0.1-SNAPSHOT [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 72, column 12 [WARNING] [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build. [WARNING] [WARNING] For this reason, future Maven versions might no longer support building such malformed projects. [WARNING]
Control official website usage: http://maven.apache.org/plugins/maven-compiler-plugin/usage.html
Initial configuration:
Org.apache.maven.plugins maven-compiler-plugin ${java.version} ${java.version} ${project.build.sourceEncoding} * {java.version} is 1.8$ {project.build.sourceEncoding} is UTF-8
The solution to this problem is to set the top maven version, the solution:
Org.apache.maven.plugins maven-compiler-plugin 3.1 ${java.version} ${java.version} ${project.build.sourceEncoding}
Second, Failed to execute goal on project pinyougou-sellergoods-interface: Could not resolve dependencies for project cn.pinyougou:pinyougou-sellergoods-interface:jar:1.0-SNAPSHOT: Failed to collect dependencies at cn.pinyougou:pinyougou-pojo:jar:1.0-SNAPSHOT.
Analysis: my pinyougou-sellergoods-interface is dependent on pinyougou:pinyougou-pojo. I have introduced pinyougou:pinyougou-pojo dependency into pinyougou-sellergoods-interface 's pom.xml file, but I still can't package the jar package using maven's install command. The solution is:
It is necessary to package the parent project with install. Because there are other sub-modules that do not have a good dependency, leave it for the time being.
Then use maven's clean command to clear the parent project.
Finally, use maven's install command for the sub-modules that need to be packaged.
Finally, the whole project is packaged. 1. Add and remove springboot built-in tomcat configuration org.springframework.boot spring-boot-starter-web org.springframework.boot spring-boot-starter-tomcat 2 in the pom.xml file, use the maven command
Clean-- > install is fine.
Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.