I want to setup a sample eclipse web project for creating spring mvc application (Without using spring tool suite). What is the best approach (OR point to me any reference)?
1. Eclipse -> new project -> dynamic web project -> add libraries
2. Eclipse -> maven -> new project -> specify archetypes OR artifactid/groupid/version etc and add libraries through dependency
3. Create spring project through mvn -generate command line tool.
Please let me know pros/cons for every setup. Apart that, I have some other queries for 3rd type. Is there any archetype for Spring mvc OR I need to generate a normal web project and then add libraries to it?
For MAVEN, do we need to really install m2eclipse? If I understand then it is already available in eclipse for JEE developers. Isn't it?
Sorry for so much queries but I am really curious.
Maven 2nd approach would be the best. maven & eclipse is standard tool.
Right but you already know that there are a lot of jars that we need to add in the POM. Including JARS directly in the eclipse build path takes less than a minute but adding all these JARS as dependency in POM will take more time. Isn't it? How to improve it or is there any best method so that these dependencies can come automatically in POM?
You should go throught the advantage of having maven.. Main reason people take the pain is to have version controlled jar. And it rebuilds only those changed classes unlike ant which rebuild all the classes.
If you really dont want to add the jars , then you can use the ANT build tool , where you only need to show the jars location or add it in the classpath.