1

I want to create a springMvc project using maven in eclipse. I have installed eclipse plugin in eclipse by following the steps shown in this answer : Maven in Eclipse: step by step installation

I didn't have the spring-mvc archetype by default so I created a new archetype with the following details

Archetype Group Id: co.ntier
Archetype Artifact Id: spring-mvc-archetype
Archetype Version: 1.0.2
Repository URL: http://maven-repository.com/artifact/co.ntier/spring-mvc-archetype/1.0.2

After doing all this, I tried creating a new maven project using the spring mvc archetype and i am getting the following error

enter image description here

Cœur
  • 37,241
  • 25
  • 195
  • 267
Minions
  • 1,273
  • 1
  • 11
  • 28
  • Yes I have that option. I get this error when I try to create a maven project using the spirng-mvc archetype – Minions Feb 11 '16 at 09:26
  • What is the problem in doing this way? – Minions Feb 11 '16 at 09:28
  • Yes! I have a quite a bit of idea about the archetypes. Basically I was trying to follow this link to create the project in eclipse : http://www.codejava.net/frameworks/spring/creating-a-spring-mvc-project-using-maven-and-eclipse-in-one-minute – Minions Feb 11 '16 at 09:38
  • If you are using a proxy connection then update that in eclipse. – Pallav Jha Feb 11 '16 at 09:42

2 Answers2

0

As cam be seen from the Archetype Group ID you have specified - co.ntier - this is not an official Spring artifact and according to the following the last release was over 3 years ago.

https://repository.sonatype.org/index.html#nexus-search;quick~spring-mvc-archetype

The post you are folowing is also over 4 years old.

On that basis you may want to consider an alternative. You can bootstrap a Spring MVC project easily by using the Spring Initialzr:

https://start.spring.io/

Enter name you want for group and artifact and select 'Web' in the dependencies. Unzip the downloaded file. In Eclipse select File > Import > Existing Maven Project and point to the root of the unzipped folder.

If you were to install Spring Tools Suite (Eclipse with some Spring related bells and whistles) you also get some additional options:

https://spring.io/tools

File > Import > Spring getting Started Content >

Alan Hay
  • 22,665
  • 4
  • 56
  • 110
0

I'm trying to create MVN project in eclipse and I faced the same problem still. So as an alternative, I create a Java Project/Dynamic Web Project in eclipse and then I convert the project into Maven and add the POM dependencies. This way I'm happy now.

Suresh
  • 1,491
  • 2
  • 22
  • 27