Chapter 21. Database Access

Database Access

Frank and some of his books © Frank Buschmann

Many business systems need to persist some or all of the data they use. Distributed systems are no exception. There is a mismatch, however, between the relational model, the dominant persistence paradigm, and the object-oriented model, the favored paradigm for distributed application development. This chapter presents five patterns that help to bridge these two models, to support mapping between object-oriented applications and relational databases.

Many software systems use databases to store their persistent data. In most of these systems the databases follow the relational model for the following reasons, mainly due to economic factors:

  • Existing legacy data and IT infrastructures. Databases are a common and long-standing feature of many IT organizations. As a result, the cost of transferring data to a different database model, or even to a different relational database, often outweigh the benefits of such a change, even if another database is technically superior.

  • Customer support. Due to the maturity of relational databases and the ecosystem that supports them, users typically receive competent and timely customer support world-wide. This level of service is not necessarily available for other database models.

  • Experience. Developers, administrators, and users of databases are often most familiar with the relational ...

Get Pattern-Oriented Software Architecture: A Pattern Language for Distributed Computing, 4th Volume now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.