Return to Home Page

The public review of the manuscript for "SOA Design Patterns" has concluded !
Thank you to all that participated. 234 reviews were received and over 30 new patterns have been contributed,
increasing the size of this book by over 50%. The second draft of the manuscript is currently in development.

About the Public Review
    History
    Podcasts (audio)
    Notification
    Submit Feedback
    Contribute a Proven Pattern
    Contribute a Candidate Pattern
    Acknowledgements
    Press Release

Introduction to SOA Types & Design Patterns
    The Architecture of
Service-Orientation
    Understanding SOA
Design Patterns

SOA Design Patterns
    Basic Service Inventory Design Pattern Language
    Architectural Design Patterns
    Basic Service Design
Pattern Language
    Service Design Patterns
    Common Compound
Design Patterns

Additional Resources
    View Entire TOC
    Symbol Legend
    Master Pattern List
(by category)
    Candidate Design Patterns
    Design Patterns Publications
    Download SOA Principles Poster (PDF)

About the Book



SOA Design Patterns
by Thomas Erl

For more information visit: www.soapatterns.com

Related Publications


Read the article "Introducing SOA Design Patterns" from the
June 2008 SOA World Magazine (High-Res PDF).

PLEASE NOTE

The content on this page is from the first draft of the manuscript for the upcoming book "SOA Design Patterns" by Thomas Erl. This version of the manuscript was authored in September, 2007. Since then, the manuscript has undergone significant content and structural changes as a result of an industry-wide review in which hundreds of SOA practitioners participated in addition to SOA vendors and experts from the design patterns community.

You are welcome to use the information on this page for research purposes, but you should assume that most of it will change in the final release of the "SOA Design Patterns" book.

Note also, that as a result of an industry-wide call for participation from December 2007 to February 2008, over 30 new design patterns have been contributed to this book. As they become finalized and are incorporated by the author, concise descriptions will be published on this site, and full descriptions with examples will be made available in the final, printed book.

Due to the volume of new content and changes, the release of the "SOA Design Patterns" book has been postponed to October, 2008. To learn more about the book, visit www.soapatterns.com. To be notified of updates to this site, use the notification form.

Chapter 6: Architectural Design Patterns

Home > Chapter 6 Overview > Data Model Transformation
Data Model Transformation

Data Model Transformation

How can services interoperate when using different data models for the same type of data?

Problem

Services may use incompatible schemas to represent the same data, hindering service interaction and composition.

Solution

A data transformation technology can be incorporated to convert data between disparate schema structures.

Application

Mapping logic needs to be developed and deployed so that data compliant to one data model can be dynamically converted to comply to a different data model.

Impacts

Data model transformation introduces development effort, design complexity, and runtime performance overhead, and overuse of this pattern can seriously inhibit service recomposition potential.

Principles

Standardized Service Contract, Service Reusability, Service Composability

Architecture

Inventory, Composition

Table 6.8 – Profile summary for the Data Model Transformation pattern.

Problem

For any service-enabled part of an enterprise where the Canonical Data Model pattern has not been successfully applied, services delivered as part of different projects run a high risk of representing similar data using different schemas.

This will typically not affect immediate service implementations, as the schemas may very well have been standardized across the initial solution or composition. However, when these same services need to be recomposed into new configurations, schema incompatibilities impose significant interoperability challenges.

Figure 6.38 – The Process Claims service represents a claim record using a different schema than the one required by the Claims service contract. This incompatibility prevents cross-service data exchange.

Solution

Data model transformation logic can be introduced to carry out the runtime conversion of data, so that data complying to one data model can be restructured to comply to a different data model. This extends a non-standardized messaging framework, enabling it to dynamically overcome disparity between the schemas used by a service contract and messages transmitted to that contract.

Figure 6.39 – Data model mapping logic is executed at runtime as part of the data exchange process, converting the structure of an XML document from the ProcessClaims schema to the Claims schema.

Application

Formalized data transformation is an established concept that dates back to the EAI era where data model incompatibilities were often resolved via broker services that existed as part of middleware platforms.

When services are implemented as Web services, XSLT is generally used to define the mapping logic that is subsequently executed to perform the transformation at runtime. In fact, the use of XSLT style sheets represents the most common application of this pattern.

Although data model transformation is a fundamental and essential part of most service-oriented architectures, it represents a pattern that is used only out of necessity. Many of the service contract patterns described in this book, in fact, result in a reduction or even an elimination of data transformation requirements. However, the realities of legacy encapsulation and common governance challenges usually introduce schema disparity that still must be dealt with.

This pattern solves an important problem, but it is equally important to be constantly aware of the fact that it is only applied when other patterns cannot be realized to their full potential. Due to the constant emphasis on Òtransformation avoidanceÓ throughout service-orientation, it is recommended to consider this pattern as a last resort.

Note: This pattern also addresses the transformation required between different versions of the same data model. For XML schemas, XSLT can also be used for this purpose.

Impacts

The use of this pattern has several predictably undesirable results:

     The development of the mapping logic adds time and effort to the creation of service compositions.

     The incorporation of data model transformation introduces design complexity into a service composition and the service inventory as a whole.

     Data model transformation introduces a runtime layer wherein the execution of mapping logic adds performance overhead every time services with disparate schemas need to exchange data.

Relationships

Canonical Data Model has a well known Òtug-of-warÓ relationship with Data Model Transformation, in that this pattern generally needs to be applied to whatever extent Canonical Data Model cannot be applied.

When in use, it can help overcome disparity between services (as per Domain Inventory and Inventory Endpoint) and also between a service and the resources it encapsulates (as per Legacy Wrapper and Rules Centralization).

Although it provides important functionality, its overuse is an anti-pattern that can undermine the goals of Capability Recomposition.

Figure 6.40 – Perhaps the most common broker pattern used in composition architectures, Data Model Transformation has many ties to a diverse collection of patterns that are affected by its application.

Data Model Transformation is a core part of Broker and Enterprise Service Bus compound patterns (Figure 6.x) and also the only broker-related pattern that is associated as an optional extension of the Orchestration compound pattern (Figure 6.x).

Figure 6.41 – The Data Model Transformation pattern is one of three transformation-related design patterns that comprise the Broker and Enterprise Service Bus compound patterns (both of which are described in Chapter 9).

Figure 6.42 – The Data Model Transformation pattern is also one of the optional patterns associated with the Orchestration compound pattern (also covered in Chapter 9).

Case study example

Case study content is not availabe on this Web site.

Prev | Next
The Prentice Hall Service-Oriented Computing Series from Thomas Erl
Home    SOA Books    SOA Magazine    What is SOA?    SOA Principles    SOA Methodology    SOA Glossary Copyright © 2007-2008
SOA Systems Inc.