This week's book giveaway is in the Performance forum.
We're giving away four copies of The Java Performance Companion and have Charlie Hunt, Monica Beckwith, Poonam Parhar, & Bengt Rutisson on-line!
See this thread for details.
Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Spring and Guice (DI Book)

 
david tanu
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi authors

What are the fundamental differences between Spring and Guice?

I know Spring is "fatter" compare to Guice.

thanks
sm
 
Dhanji Prasanna
author
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Spring and Guice take slightly different approaches, historically. Spring has focused more on being a complete Enterprise Java stack, whereas Guice focuses purely on DI.

There are several comparisons around the web that get quite partisan, but mostly the difference has been that Guice's philosophy is around modularity and type safe configuration, and Spring's has traditionally been around flexibility and complete solutions for integration with third party libraries. Nowadays they both provide similar features and there is even a joint effort (JSR-330) between Google and SpringSource to standardize DI for Java.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic