Create Spring MVC project using Maven

I showed you how to Create Spring web application using Spring Legacy Project in Spring Tool Suite 3. The disadvantage of this way is that you have to use Spring Tool Suite 3 even though Spring Tool Suite 4 has been released a long time ago. In addition, after creating the project, you have to update and edit the dependencies, then add the Maven Jetty Plugin to run the application quickly. Seeing these inadequacies, I created a new Maven Archetype project, published it to Central Maven Repository so that you can easily create a new Spring MVC application and use it without having to spend so much effort. Now, if you want to create a new Spring MVC project with Maven, you can use huongdanjava-springmvc-archetype.

Specifically, if you are using Eclipse to create a new Spring MVC project using Maven, in the “Select an Archetype” window of Eclipse, you can filter and select your huongdanjava-springmvc-archetype project as follows:

Click Next to enter project information:

The result will be as follows:

My Maven Archetype project has already declared the Maven Jetty Plugin, so you just need to run it.

The following results:

Add Comment