Enterprise Integration Patterns
Messaging Patterns
Messaging Patterns
Canonical Data ModelMessaging Patterns » Message Transformation

I am designing several applications to work together through Messaging. Each application has its own internal data format.

How can you minimize dependencies when integrating applications that use different data formats?

Therefore, design a Canonical Data Model that is independent from any specific application. Require each application to produce and consume messages in this common format.

The Canonical Data Model provides an additional level of indirection between application's individual data formats. If a new application is added to the integration solution only transformation between the Canonical Data Model has to created, independent from the number of applications that already participate.

The use a Canonical Data Model seems complicated if only a small number of applications participate in the integration solution. However, the solution quickly pays off as the number of applications increases. If we assume that each application sends and receives message to and from each other application, a solution consisting of 2 applications would require only 2 Message Translators if we translate between the applications' data formats directly whereas the Canonical Data Model requires 4 Message Translators. A solution consisting of 3 applications requires 6 Message Translators with either approach. However, a solution consisting of 6 applications requires 30(!) Message Translators without a Canonical Data Model and only 12 Message Translators when using a Canonical Data Model.

... Read the entire pattern in the book Enterprise Integration Patterns

Related patterns:

Format Indicator, Message Channel, Message Router, Introduction to Message Routing, Message Translator, Messaging, Messaging Mapper, Shared Database

Creative Commons Attribution License

You can reuse the following elements under the Creative Commons Attribution license: pattern icon, pattern name, problem and solution statements (in bold), and the sketch. Other portions are protected by copyright.

Enterprise Integration Patterns book cover

Enterprise Integration Patterns
The classic, as relevant as ever. Over 90,000 copies sold.

Software Architect Elevator book cover

The Software Architect Elevator
Learn how architects can play a critical role in IT transformation by applying their technical, communication, and organizational skills.

Cloud Strategy book cover

Cloud Strategy
Fill the large gap between high-level goals and product details by understanding decision trade-offs.