A friend of mine is starting to use Unity with WCF, and I looked up a rather simple but good set of articles on Unity with WCF:
I’ve personally used Castle Windsor’s WCF facility, but for all intent purposes, they are doing the same thing.
If you aren’t using DI with an IOC, I strongly suggest you learn about itand integrate it into your code. The benefits are fantastic and help promote good separation of concerns, easier to test your code, etc…
There are plenty of .NET IOC containers available. Learn more about each below:
- Unity Application Block – patterns and practice team (fyi – if you are using logging, etc… they are using Unity under the covers – might be a good place to start if you are in a ‘P&P application blocks’ environment.
- Windsor – Castle Project (there is a WCF ‘facility’) – here is good example post on usage
- Spring.NET – spring
- Structure Map