I'm trying to follow a tutorial from a site about Spring mvc. And there the very first step was to create a project in Spring STS 3.0.0. I downloaded that and created a project as it described.
But the project structure was not the same and there are some errors also.
Cannot read lifecycle mapping metadata for artifact org.apache.maven.plugins:maven-war-plugin:maven-plugin:2.1.1:runtime Cause: error in opening zip file
As in the picture the Maven Dependencies
and JRE System Library
are missing here. And in the POM.xml there is the above error also.
The expected project structure is,
And when I try to `clean install the project it will also failed.
Failed to parse plugin descriptor for org.apache.maven.plugins:maven-war-plugin:2.1.1 (C:\\Users\\Intel\\.m2\\repository\\org\\apache\\maven\\plugins\\maven-war-plugin\\2.1.1\\maven-war-plugin-2.1.1.jar): error in opening zip file -> [Help 1]
What am I missing here ?
I used org.apache.maven.archetypes / maven-archetype-webapp / 1.0
To create a proper Spring MVC project, you need to create new spring template project named as "Spring MVC project"
which sometimes you need to download it first. You can refer it here :
http://www.codejava.net/frameworks/spring/spring-mvc-beginner-tutorial-with-spring-tool-suite-ide
If you cannot find the Spring MVC Project
, click on new project->Spring Legacy Project first then the template will be there. After that the,the template will create the proper Spring MVC Project with proper setup of Maven.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.