Contracts and interop

Home | Blog | Bio and Contact | CSLA .NET | CSLA Store

23 February 2005

Just a super-quick entry that I’ll hopefully follow up on later. Ted wrote a bunch of stuff on contracts related to Indigo, etc.

I think this is all wrong-headed. The idea of being loosely coupled and the idea of being bound by a contract are in direct conflict with each other. If your service only accepts messages conforming to a strict contract (XSD, C#, VB or whatever) then it is impossible to be loosely coupled. Clients that can’t conform to the contract can’t play, and the service can never ever change the contract so it becomes locked in time.

Contract-based thinking was all the rage with COM, and look where it got us. Cool things like DoWork(), DoWork2(), DoWorkEx(), DoWorkEx2() and more.

Is this really the future of services? You gotta be kidding!