Does anyone know difference between Struts2 and Spring 3 MVC. I know the difference between Struts 1 and Spring 2.5, but what's the advantage Struts2 has over Spring 3 or otherwise.
I tried looking all over web, but there is no comprehensive answer anywhere.
Spring framework is more efficient than struts but sometimes spring framework provides complexity but in struts, everything is simple due to its easy and maintainable design. Spring framework has more functionality than struts. Spring MVC is mainly used because it is more secure and better performance.
Apache Struts 2 is an open-source web application framework for developing Java EE web applications. It uses and extends the Java Servlet API to encourage developers to adopt a model–view–controller (MVC) architecture.
Spring MVC is an equivalent with Struts so you don't use them together. But it is ok to combine Struts and Spring IoC. Show activity on this post. Struts - usually provides MVC framework (most of Production support & maintenance applications are already integrated with it).
Struts2 is really WebWork 2 renamed as Struts2. Consider for a moment the fact that Struts essentially leveraged its own brand name to adopt WebWork as its new base, and that should suggest to you that there was at least some who felt it was very compelling -- one doesn't always throw out their own code base to start anew when they issue a sequel.
That said, I'm not going to tell you that Struts2 is better/worse than Spring 3 MVC. Bottom line is that they are definitely comparable.
If you want more details on how they compare, I suggest you check out Matt Raible's presentations in years past on this topic:
http://raibledesigns.com/rd/entry/my_comparing_jvm_web_frameworks
http://static.raibledesigns.com/repository/presentations/ComparingJavaWebFrameworks-ApacheConUS2007.pdf
including a spreadsheet that compares several of them on various degrees:
http://spreadsheets.google.com/pub?key=0AtkkDCT2WDMXdC1HOEtnUHpCejJMbUhGeGJWUmh5dVE&hl=en&output=html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With