C
CIOPages
Back to Glossary

Architecture Patterns

Adapter Pattern

The Adapter Pattern is a structural design pattern that allows incompatible interfaces to work together by wrapping one interface with a class or module that translates calls between the incompatible systems, enabling integration without modifying either the client or the adapted service's source code.

Context for Technology Leaders

For CIOs, the Adapter Pattern is fundamental to enterprise integration, enabling legacy systems to interact with modern services, third-party APIs to conform to internal standards, and vendor products to integrate into existing architectures without modification. Enterprise architects use adapters extensively in integration architectures.

Key Principles

  • 1Interface Translation: Adapters translate between incompatible interfaces, converting data formats, protocols, and calling conventions without requiring changes to either side.
  • 2Integration Flexibility: New systems can integrate with legacy or third-party systems through adapters rather than requiring modifications to either side's interface.
  • 3Vendor Abstraction: Adapters create abstraction layers over vendor-specific APIs, enabling vendor replacement without modifying the consuming application.
  • 4Testing Enablement: Adapters can be replaced with test doubles (mocks, stubs) that simulate external systems, enabling isolated testing of application logic.

Strategic Implications for CIOs

Enterprise architects should standardize adapter patterns for common integration scenarios—database adapters, messaging adapters, external API adapters—and provide templates that teams can implement consistently.

Common Misconception

A common misconception is that adapters are temporary solutions to be removed during modernization. Many adapters provide permanent value by abstracting volatile external interfaces, enabling vendor flexibility, and isolating integration complexity from domain logic.

Related Terms