04/30/09 :: [SOA] Coupling [permalink]

I have started a discussion with Ian Robinson on his latest post looking at Temporal and Behavioral Coupling.

His post echoes somewhat Jim Webber's post on Cohesion and Loose Coupling. For some reason, I felt that both these posts came to erroneous conclusions. Yes of course principles of cohesion and coupling ought to be considered when designing a system. This is not what I am arguing.

It struck me this morning that SOA has changed software engineering forever by enabling contracts to become "virtual". I don't think anyone is more passionate about this topic and explains it better than William Oellermann. I have also expressed many times that the Contract is about expressing "intent" not invoking a particular piece of code. Applying good old software engineering principles (which all actually revolved around the idea of designing better contracts) is at best risky.

IMHO, both Ian and Jim do not take into account the ability to decouple the contract from the implementation. I would argue that this is probably the most fundamental principle of Service Oriented Architecture, or more exactly connected system architecture. It is critical to define very clearly intent (action) and whether or not a particular intent was achieved successfully (event). Of course a few annotations later, most middleware vendors have completely forgotten this principle, but nevertheless, it is the most foundational principle set forth a decade ago.

That being said, I would argue that it is wrong to oppose commands and events, they are both complementary in establishing intent. I would also argue that a synchronous interaction where the intent is directly wired to a particular agent and the completion is notified synchronously to the sole requestor is the root of all problems in the design of connected systems.

This is why I am so opposed to the (other) REST -as a connected system programming model. REST, not only, has no ability to express intent and support events but offers absolutely no ability to decouple intent from implementation.