Arifur Rahman
Arifur Rahman

Reputation: 1

What the difference between struts2 and spring MVC

I am learning Java EE and wanna build up a complete management system for a restaurant. Now I am confused what presentation layer should I use for my RMS because I heard that the struts 2 is one of the best UI layer but, the thing is, if I am using spring for my business logic layer then I can use the spring MVC can't I? By the way, I am really interested to build a complete application which is follow the multi-tier architecture.

Upvotes: 0

Views: 2321

Answers (2)

duffymo
duffymo

Reputation: 308733

Yes, of course you can use Spring MVC.

You can use Struts 2 if you'd like as well, because Spring integrates with it nicely.

But I don't see any reason why you'd want to do that. The person who told you that Struts 2 is

one of the best UI layer [sic]

is misguided. If you compare it to Spring MVC, you'll see that the two are based on similar ideas, but Spring improves on Struts. JSF has superceded Struts as the default Java EE web view technology, so it's not even considered "best" by the Java EE standard.

Stick with Spring. You won't be sorry.

Upvotes: 1

Alban
Alban

Reputation: 1943

I will not blame struts 2, indeed it's a great product, I work with it every day. But in my experience spring MVC is a lot simpler and clearer. This doesn't mean you don't get as much features.

Try both, and you'll see what I mean. Tell us which one you choose!

Upvotes: 0

Related Questions