Javatpoint Logo

what are differences between Spring and Struts

By: thiruk*** On: Fri Apr 19 22:33:24 IST 2013     Question Reputation14 Answer Reputation0 Quiz Belt Series Points0  14Blank User
Please list the major difference between structs and springsUp2Down

 
we use both Spring and Struts, they are not an either/or proposition. Struts is the front end, ActionForms and Actions. Actions will call the Spring Service which has the Spring DAO injected into it. Spring makes unit testing sooooo much easier, you can inject your fake dao and not have to test with the database at all if you do not want to. we use it with Hibernate and my code is quite small as Spring handles expceptions quite well and you are relieved of all the Hibernate repetitive code.

Differences:

1)Struts is a web framework while Spring is not.

2)Spring is a Layered Architecture while Struts is not.

3)Struts is heavy weight while Spring is light weight.

4)Struts supports tag Library while Spring does not.

5)Spring is loosely coupled while Struts is tightly coupled.

6)Spring provides easy integration with ORM technologies while in struts, we need to do coding manually.

7)Struts easily integrate with other client side technologies. It is not easy in case of spring.
Image Created0Down

By: [email protected] On: Sat Apr 20 13:39:23 IST 2013 Question Reputation0 Answer Reputation147 Belt Series Points0 147User Image
Are You Satisfied :29Yes24No
 
How do you say spring is a Layered Architecture and structs is not?
how do you say Spring is loosely coupled and Struts Doesn't and can you please ellobarate briefly?
Image Created0Down

By: [email protected] On: Sat Apr 20 17:33:00 IST 2013 Question Reputation14 Answer Reputation0 Belt Series Points0 14User Image
Are You Satisfied :8Yes3No