Wednesday, August 16, 2006

Which IoC Container?

I've used Spring successfully in Java projects. It is hard for me to understate how wonderful it is. I have always felt that the real benefit of IoC containers is that they promote good programming practices, in particular programming to interfaces which enables TDD. Of course ultimately you use the container to manage your dependencies but this is nothing that can't be achieved using the Service Locator pattern. The additional win of IoC is that there is no dependency on the Service Locator itself.

As I hinted in my previous posting it is time to consider an IoC container for .NET. My initial thoughts were to turn to Spring but the .NET version is very immature compared to its Java compatriot, especially outside of the core DI features (Hibernate integration, JDBC templates and declarative transactions spring to mind...if you pardon the pun). Jeremy Miller's Structure map and the Castle project are alternatives.

So it's time to do some research and determine which option best suits my needs.

0 Comments:

Post a Comment

<< Home