From OpenNMS
Migrating OpenNMS to Spring
The Spring Framework will make the OpenNMS code both easier to code to and easier to use. Here are a few of the ways it helps with this:
- Easier To Test
- Code written to use the Spring Framework is written to enable dependency injection. This makes for code that is simpler to test because you can make 'mock' implementations of objects in your tests and inject them yourself making for less test harness code.
- More Loosely Coupled
- Dependency injection also makes for code that is more loosely coupled because objects are passed in that implement interfaces rather than writing look up code in each object.
- Proxy-able
- Spring has AOP Concepts that allow for the automagical generation of proxies that allow object be simply remoted without writing any extra code. This will be essential when we want to distribute OpenNMS. When using Spring interfaces we set a number of proxy 'points' that enable us to remote that interface to another JVM or system.
I am sure there are other advantages such as declarative transactions support, more fine-grained security, a clean web framework, flexible integration with other framework, etc.
Any thoughts on this?






