Alternatives to Spring

Going back to our previous comments on the number of open source projects, you should not be surprised to learn that Spring is not the only framework offering Dependency Injection features or full end-to-end solutions for building applications. In fact, there are almost too many projects to mention. In the spirit of being open, we include a brief discussion of several of these frameworks here, but it is our belief that none of these platforms offers quite as comprehensive a solution as that available in Spring.


PicoContainer ( is an exceptionally small (50k) DI container that allows you to use DI for your application without introducing any other dependencies other than PicoContainer itself. Because PicoContainer is nothing more than a DI container, you may find that as your application grows, you need to introduce another framework, such as Spring, in which case you would have been better off using Spring from the start. However, if all you need is a tiny DI container, then PicoContainer is a good choice, but since Spring packages the DI container separate from the rest of the framework, you can just as easily use that and keep the flexibility for the future.


NanoContainer ( is an extension to PicoContainer for managing trees of individual PicoContainers. Because Spring provides all the same functionality in the standard DI container, NanoContainer is not really a major improvement over Spring. Where NanoContainer becomes interesting is in its support for scripting languages that interact with the container. However, expect to see this functionality in Spring in the near future.

Keel Framework

The Keel Framework ( is more of a meta-framework in that most of its capabilities come from other frameworks that are all brought together under a single roof. For instance, DI functionality comes from the Apache Avalon container and web functionality comes from Struts or a similar framework. Keel has many implementations of the same components and links them all together into a cohesive structure, allowing you to swap out implementations with minimal impact on your application. Despite its wide feature set, Keel does not seem to have enjoyed the same level of acceptance as Spring. Although we have investigated Keel only briefly, we feel that this is partially to do with the level of accessibility. Spring is immediately accessible to developers of all levels, whereas Keel seems to be more complex. Having said that, the feature set is impressive, and this is certainly a direct competitor to Spring.

Pro Spring
Pro Spring
ISBN: 1590594614
EAN: 2147483647
Year: 2006
Pages: 189

Similar book on Amazon © 2008-2017.
If you may any questions please contact us: