Smart endpoints and dumb pipes

This page is published under the terms of the licence summarized in the footnote.

Smart pipes

Martin Fowler points out that many products and approaches put significant intelligence into the communication mechanism itself.

E.g. an Enterprise Service Bus (ESB) includes sophisticated facilities for message routing, choreography, transformation, and applying business rules.

Smart endpoints and dumb pipes

By contrast micro apps are as decoupled and as cohesive as possible - they own their own domain logic.

They are choreographed using simple protocols (rather than complex ones such as WS-Choreography, BPEL or orchestration by an ESB).

The two protocols used most commonly are:

 

HTTP request-response with resource API's

Teams use the principles and protocols that the world wide web (and to a large extent, Unix) is built on.

Oft-used resources can be cached with little effort on the part of developers or operations folk.

 

Lightweight messaging

Dumb infrastructure - acts as a message router only.

Simple products (as RabbitMQ or ZeroMQ) don't do much more than provide a reliable asynchronous fabric.

 

Again, there is a down side to using remote interoperation mechanisms.

Modularisation and decoupling tends to change the internal system design.

Inside a macro app, communication between modules is via local procedure calls.

Dividing it into micro apps requires changing the communication pattern.

Simple conversion from in-memory LPC to RPC leads to chatty communications which don't perform well.

So, you need to replace the fine-grained communication with a coarser -grained approach.

Modularisation and decoupling tends to change the external business process.

It tends to mean accepting user commands and embarking on business processes that later have to be abandoned.

This issue is explored in our paper on CQRS.

 

 

Footnote: Creative Commons Attribution-No Derivative Works Licence 2.0                        23/12/2014 14:46

Attribution: You may copy, distribute and display this copyrighted work only if you clearly credit “Avancier Limited: http://avancier.co.uk” before the start and include this footnote at the end.

No Derivative Works: You may copy, distribute, display only complete and verbatim copies of this page, not derivative works based upon it.

For more information about the licence, see  http://creativecommons.org