It's not a secret anymore!
The moose likes Struts and the fly likes Struts 2.0 and Spring!! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 2.0 and Spring!!" Watch "Struts 2.0 and Spring!!" New topic

Struts 2.0 and Spring!!

Tom Rader

Joined: Jan 23, 2010
Posts: 5
Hello All,

I am developing a product. I want to use Struts 2.0 with hibernate. One of my friend told me that If I am using Struts 2.0 I should also use Spring!!!

Should I use spring If yes then please specify the reason also.

Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 10032

It is not that if you use Struts 2.0 you should use Spring. In general Spring is considered to be used as a candidate wherein the objects that your application would need and their dependencies are managed with ease provided the richness of building a transactional, distributed computing is easily achieved using Spring. Spring offers very good integration with some well known and widely used frameworks like Hibernate, Struts, EJB, JSF and many more. What this integration mean is that you get to use those frameworks also with ease by letting Spring control them.

SCJP 1.4, SCWCD 1.4 - Hints for you, Certified Scrum Master
Did a rm -R / to find out that I lost my entire Linux installation!
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 10032

So in my opinion, you should definitely use Spring.
I agree. Here's the link:
subject: Struts 2.0 and Spring!!
jQuery in Action, 3rd edition