Data Access Patterns
Just as design patterns document solutions to common design problems, data access patterns have a similar role within the field of data access. The data access patterns in this book describe common abstractions for solutions that you can apply directly within your own applications. Some data access patterns are so universally applicable that many commercial products implement them by default. Resource Pool (117) and Object/Relational Map (53) are two such examples. Application servers or plumbing platforms that implement patterns like these save you from building the same infrastructure on your own.
Other data access patterns are less pervasive, but still apply across many application domains. For example, data caching is a common optimization, but you must implement it carefully so that you do not impose more overhead than the physical database operations you are trying to avoid issuing do. In this respect, you must consider specific usage patterns and the nature of the data to be cached. These are characteristics to which a more generic product might have a difficult time adapting.
|