This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
As far as I can tell, these two are different approaches to web application programming. However I would like to know the main differences between them and which is preferable? Hope someone can answer my trivial question.
The bottomline is this. If you have a "small application" and speed of development is of the essence, perhaps you are better off just using plain Servlets and JSPs. The moment it starts becoming something "large" and/or it has a lot of incremental changes expected, a formal framework is best employed. Struts is the most popular framework for Java web applications. It has its shortcomings, but it also has a lot of industry adoption as well as a strong user community.
I suggest you look at some basic Struts tutorials to get an idea of what it would offer you. Then you can decide if the learning curve is worth your while (for the application you have in mind). Let us know if you have more specific questions.
I just suggest that if you develop a big web application , and your custom want to offer small lund , then you will use Eclipse + Jboss + mySql + Junit + Ant + Struts + Hibernate + String . and you will find them are very very strong and good