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 8: Service Design Patterns

Home > Chapter 8 Overview > Schema Centralization
Schema Centralization

Schema Centralization

How can service contracts be designed to avoid redundant data representation?

Problem

Different service contracts often need to express capabilities that process similar data sets, resulting in redundant schema content that is difficult to govern.

Solution

Select schemas that exist as physically separate parts of the service contract are shared across multiple contracts.

Application

Upfront analysis effort is required to establish a schema layer independent of and in support of the service layer.

Impacts

Governance of shared schemas becomes increasingly important as multiple services can form dependencies on the same schema definitions.

Principles

Standardized Service Contract, Service Loose Coupling

Architecture

Inventory, Service

Table 8.10 – Profile summary for the Schema Centralization pattern.

Problem

When building services for larger enterprise environments the context established by each service boundary will usually not be exclusive to one body of data. For example a Claims Service will represent a collection of claims-related functions and will therefore be primarily responsible for processing claims data. However, even though it will be positioned as a primary endpoint for that body of functionality, it will likely not be the only service to work with claims data.

As a result, the need for duplicate schema data models emerges, leading to the definition of service contracts with redundant content. Even if the data models across these contracts are standardized, the redundant and decentralized implementation of contract schemas introduces constant governance challenges primarily associated with keeping schema data models in synch.

Figure 8.36 A set of WSDL definitions for which a corresponding set of XML Schemas has been custom tailored. This has the appearance of a very clean contract architecture, but it actually can introduce significant schema redundancy as indicated by the shaded areas.

Solution

Schemas can be designed and implemented independently from the service capabilities that utilize them to represent the structure and typing of message content. As a result, a schema data model architecture can be established and standardized somewhat separately from the parent service layer. For example, if one schema representing claims data is defined, any service with a capability that needs to process claims data would use the same schema.

Figure 8.37 WSDL definitions that share common XML schemas end up sharing the same message data models. The reduction of redundant content also results in smaller sized schemas.

Application

What is primarily advocated by this pattern is the creation of an independent schema (or data representation) architecture. This architecture may already exist within an organization, especially if serious XML schema standardization efforts have already been carried out. However, if schemas need to be defined as part of the SOA initiative, then it is recommended that they be created prior to the completion of individual service contracts.

Ideally, the incorporation of the separate schema layer is taken into account subsequent to the completion of the service inventory blueprint, in preparation for the delivery of the physical service inventory.

 

Essentially, the following sequence is suggested:

1.     Complete a service inventory blueprint to establish a conceptual representation of planned services within an inventory.

2.     Determine the required centralized schema definitions to represent the common business entities and information sets likely to be processed by services in this inventory.

3.     Create the schema definitions by applying design standards to ensure consistency and normalization.

4.     Create the WSDL definitions using the standard schemas wherever appropriate, and supplementing the contract with any required service-specific schemas.

Impacts

Because of the dependencies formed on the shared schema definitions, their initial design is crucial. After multiple service contracts form links to a schema, the evolution of the schema definition thereafter becomes a key part of the overall service inventory governance. Any change to a centralized schema can affect numerous contracts.

For larger organizations, this level of data standardization can pose daunting challenges, many of which revolve around the maintenance of the shared schemas and the enforcement of associated design standards.

Note: Even though this design pattern advocates the avoidance of redundant schema content, in most environments it is common to supplement centralized schemas with service specific schemas. It can be impractical and even impossible to centralize all schemas within an inventory.

Relationships

The schema layer established by Schema Centralization can be built upon and further incorporated as part of a Contract Centralization effort and, due to its emphasis on reducing data model redundancy, also carries forward the goals of Service Normalization into the data tier.

An interesting relationship can exist between this pattern and Validation Abstraction in that the creation of official, centralized schemas can bring with it more detail than all services may actually require. This can end up countering some of the optimizing and information hiding goals of Validation Abstraction.

Figure 8.38 – The Schema Centralization pattern has few relationships because its scope is limited to an independent, underlying data model tier.

Case Study Example

Case study content is not available 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.