How Can We Help?
Patterns of Enterprise Application Architecture
Domain Logic Patterns
Transaction Script
- Organises business logic by procedures where each procedure handles a single request from the presentation.
- https://www.martinfowler.com/eaaCatalog/transactionScript.html
Domain Model
- An object model of the domain that incorporates both behaviour and data.
- https://www.martinfowler.com/eaaCatalog/domainModel.html
Table Model
- A single instance that handles the business logic for all rows in a database table or view.
- https://www.martinfowler.com/eaaCatalog/tableModule.html
Service Layer
- Defines an application’s boundary with a layer of services that establishes a set of available operations and coordinates the application’s response in each operation.
- https://www.martinfowler.com/eaaCatalog/serviceLayer.html
Data Source Architectural Patterns
Table Data Gateway
- An object that acts as a Gateway to a database table. One instance handles all the rows in the table.
- https://www.martinfowler.com/eaaCatalog/tableDataGateway.html
Row Data Gateway
- An object that acts as a Gateway to a single record in a data source. There is one instance per row.
- https://www.martinfowler.com/eaaCatalog/rowDataGateway.html
Active Record
- An object that wraps a row in a database table or view, encapsulates the database access, and adds domain logic on that data.
- https://www.martinfowler.com/eaaCatalog/activeRecord.html
Data Mapper
- A layer of Mappers that moves data between objects and a database while keeping them independent of each other and the mapper itself.
- https://www.martinfowler.com/eaaCatalog/dataMapper.html
Object-Relational Behavioural Patterns
Unit of Work
- Maintains a list objects affected by a business transaction and coordinates the writing out of changes and the resolution of concurrency problems.
- https://www.martinfowler.com/eaaCatalog/unitOfWork.html
Identity Map
- Ensures that each object gets loaded only once by keeping every loaded object in a map. Looks up objects using the map when referring to them.
- https://www.martinfowler.com/eaaCatalog/identityMap.html
Lazy Load
- An object that doesn’t contain all of the data you need but knows how to get it.
- https://www.martinfowler.com/eaaCatalog/lazyLoad.html
Object-Relational Structural Patterns
Identity Field
- Saves a database ID field in an object to maintain identity between an in-memory object and a database row.
- https://www.martinfowler.com/eaaCatalog/identityField.html
Foreign Key Mapping
- Maps an association between objects to a foreign key reference between tables.
- https://www.martinfowler.com/eaaCatalog/foreignKeyMapping.html
Association Table Mapping
- Saves an association as a table with foreign keys to the tables that are linked by the association.
- https://www.martinfowler.com/eaaCatalog/associationTableMapping.html
Dependent Mapping
- Has one class performs the database mapping for a child class.
- https://www.martinfowler.com/eaaCatalog/dependentMapping.html
Embedded Value
- Maps an object into separate fields of another object’s table.
- https://www.martinfowler.com/eaaCatalog/embeddedValue.html
Serialised LOB
- Saves a graph of objects by serialising them into a single are object (LOB), which it stores in a database field.
- https://www.martinfowler.com/eaaCatalog/serializedLOB.html
Class Table Inheritance
- Represents an inheritance hierarchy of classes with one table for each class.
- https://www.martinfowler.com/eaaCatalog/classTableInheritance.html
Concrete Table Inheritance
- Represents an inheritance hierarchy of classes with one table per concrete class in the hierarchy.
- https://www.martinfowler.com/eaaCatalog/concreteTableInheritance.html
Inheritance Mappers
- A structure to organise database mappers that handle inheritance hierarchies.
- https://www.martinfowler.com/eaaCatalog/inheritanceMappers.html
Object-Relational Metadata Mapping Patterns
Metadata Mapping
- Holds details of object-relational mapping in metadata.
- https://www.martinfowler.com/eaaCatalog/metadataMapping.html
Query Object
- An object that represents a database query.
- https://www.martinfowler.com/eaaCatalog/queryObject.html
Repository
- Mediates between the domain and data mapping layers using a collection-like interface for accessing domain objects.
- https://www.martinfowler.com/eaaCatalog/repository.html
Web Presentation Patterns
Model View Controller
- Splits user interface interaction into three distinct roles.
- https://www.martinfowler.com/eaaCatalog/modelViewController.html
Page Controller
- An object that handles a request for a specific page or action on a Web site.
- https://www.martinfowler.com/eaaCatalog/pageController.html
Front Controller
- A controller that handles all requests for a Web site.
- https://www.martinfowler.com/eaaCatalog/frontController.html
Template View
- Renders information into HTML by embedding markers in an HTML page.
- https://www.martinfowler.com/eaaCatalog/templateView.html
Transform View
- A view that processes domain data element by element and transforms it into HMTL.
- https://www.martinfowler.com/eaaCatalog/transformView.html
Two Step View
- Turns domain data into HTML in two steps: first by forming some kind of logical page, then rendering the logical page into HTML.
- https://www.martinfowler.com/eaaCatalog/twoStepView.html
Application Controller
- A centralised point for handling screen navigation and the few of an application.
- https://www.martinfowler.com/eaaCatalog/applicationController.html
Distribution Patterns
Remote Facade
- Provides a coarse-grained facade on fine-grained objects to improve efficiency over a network.
- https://www.martinfowler.com/eaaCatalog/remoteFacade.html
Data Transfer Object
- An object that carries data between processes in order to reduce the number of method calls.
- https://www.martinfowler.com/eaaCatalog/dataTransferObject.html
Offline Concurrency Patterns
Optimistic Offline Lock
- Prevents conflicts between concurrent business transactions by detecting a conflict and rolling back the transaction.
- https://www.martinfowler.com/eaaCatalog/optimisticOfflineLock.html
Pessimistic Offline Lock
- Prevents conflicts between concurrent business transactions by by allowing only one business transaction at a time to access data.
- https://www.martinfowler.com/eaaCatalog/pessimisticOfflineLock.html
Coarse-Grained Lock
- Locks a set of related objects with a single lock.
- https://www.martinfowler.com/eaaCatalog/coarseGrainedLock.html
Implicit Lock
- Allows framework or layer supertype code to acquire offline locks.
- https://www.martinfowler.com/eaaCatalog/implicitLock.html
Session State Patterns
Client Session State
- Stores session state on the client.
- https://www.martinfowler.com/eaaCatalog/clientSessionState.html
Server Session State
- Keeps the session state on a server system in a serialised form.
- https://www.martinfowler.com/eaaCatalog/serverSessionState.html
Database Session State
- Stores session data as committed data in the database.
- https://www.martinfowler.com/eaaCatalog/databaseSessionState.html
Base Patterns
Gateway
- An object that encapsulates access to an external system or resource.
- https://www.martinfowler.com/eaaCatalog/gateway.html
Mapper
- An object that sets up a communication between two independent objects.
- https://www.martinfowler.com/eaaCatalog/mapper.html
Layer Supertype
- A type that acts a supertype for all types in its layer.
- https://www.martinfowler.com/eaaCatalog/layerSupertype.html
Separated Interface
- Defines an interface in a separate package from its implementation.
- https://www.martinfowler.com/eaaCatalog/separatedInterface.html
Registry
- A well-known object that other objects can use to find common objects and services.
- https://www.martinfowler.com/eaaCatalog/registry.html
Value Object
- A small simple object, like money or a date range, whose equality isn’t based on identity.
- https://www.martinfowler.com/eaaCatalog/valueObject.html
Money
- Represents a monetary value.
- https://www.martinfowler.com/eaaCatalog/money.html
Special Case
- A subclass that provides special behaviour from particular cases.
- https://www.martinfowler.com/eaaCatalog/specialCase.html
Plugin
- Links classes during configuration rather than compilation.
- https://www.martinfowler.com/eaaCatalog/plugin.html
Service Stub
- Removes dependence upon problematic services during testing.
- https://www.martinfowler.com/eaaCatalog/serviceStub.html
Record Set
- An in-memory representation of tabular data.
- https://www.martinfowler.com/eaaCatalog/recordSet.html
Useful Links
- Enterprise Integration Patterns
-
Enterprise Integration Patterns: Designing, Building, and Deploying Messaging Solutions (Amazon)