What defines a Service Contract

The public re-unveiling of Indigo at VSLive last week has ignited some “lively discussion” in .NET circles about what defines a service contract. As Don Box says here in Indigo you can expose a service contract as either WSDL or annotated CLR interfaces, but neither is the “real” service contract. Clemens (ever ready to inflame discussion and drive hits to his weblog) said that in this brave new ultra-violet world staring at angle-brackets was now deprecated, which was like calling their kids ugly to Tim Ewald and Aaron Skonnard. Steve Maine had some thoughts on contracts and isomorphism which I am still trying to internalize.

From my naive perspective, at a conceptual level it probably doesn’t matter how your contracts are expressed, since any interpretation of said contract will be subjective. However, if you’re going to use some contract format at least use/care about the most common one (WSDL) since that would (hopefully) give a better chance of effective communication. The best analogy I can think of at 2:30 AM is this - since all communication is subjective I COULD try and communicate with my wife (if she was awake at 2:30 AM) by using pointing and gestures, however since both of us speak english and it has richer semantics that pointing and arm waving I could also give that a try. Speaking english with my wife won’t guarantee perfect communication, but since it is a common format that both of us understand it might just work. Maybe internally I THINK in terms of pointing and gestures, but I need to translate that into english to speak to her, or else rely on her doing the translation for me. I’m sure I’ll read my ramblings tomorrow and cringe (or maybe start waving my arms).