Create Dynamic Web Project using Maven from eclipse wtp

 

What are we going to learn? 

  Creating maven web project and deploy to tomcat from eclipse.

 
How ?
   By using maven archetype through eclipse.
 
Web Project through eclipse:
    
    In eclipse, go to 
 
									
    File -> New -> Other -> Expand Maven -> Select Maven Project -> Next 
New Wizard Maven Selection
 
    On New Maven Project Wizard select web archetype as shown below
 
Archetype Selection
 
    In the next screen, provide Group Id which the package and Artifact Id which will be the        project name.
 
Artifact and Group Id
 
On completion, a new project is created in the work space. The structure would be as under :
 
Project structure

Go to JEE perspective in eclipse and deploy the application as shown below 

Server Add Project
Add Project
 
On Finish, the project is deployed to the tomcat server. The application can be published for new changes and removed using "Publish" and "Remove" options.
 
Access the application through 
http://localhost:8080/SpringMVCProject/
 
 
That's It !
Web Analytics