Home

 

Enterprise patterns

Enterprise design patterns build on the GoF design patterns discussed previously and catalog design patterns that are applicable for distributed enterprise systems. In a similar way to the GoF patterns, they have come about from the fact that developers found tried and proven design solutions to recurring problems in the contexts found in distributed enterprise systems. They are widely applied when creating Java EE systems.

The original enterprise pattern catalog was produced when Java 2 Enterprise Edition (J2EE) was widely used. Although J2EE has evolved to become Java EE 5 many of the patterns are still relevant.

The enterprise patterns catalog organizes the patterns into three groups based on the fact that enterprise applications use the multi-tier architectural pattern and most enterprise patterns are specific to a particular tier:

Presentation (Web) Tier Patterns. The patterns in this group are concerned with the management of views and the presentation of information to clients. Example patterns in this group are Front Controller and View Helper.

Business (EJB) Tier Patterns. The patterns in this group are concerned with persistence and the processing of business information (business logic). Example patterns in this group are Session Facade, Service Locator and Business Delegate.

Integration Tier Patterns. The patterns in this group are concerned with the integration of one enterprise system with another and the integration of enterprise systems with other systems such as database servers. Example patterns in this group are: Data Access Object and Service Activator.

Some support is available within Rational Application Developer for enterprise design patterns. This is in addition to the refactoring facilities and the use of class diagrams as discussed previously for the GoF patterns. One example concerns EJB 2.1 entity beans. It is possible to select an EJB 2.1 entity bean in the Enterprise Explorer, and through the context menu apply the Session Facade pattern to automatically generate a session bean facade for the entity bean. Figure | -9 shows the context menu and the Create Session Bean Facade entry in the menu.

Figure 6-9 Applying the Session Facade pattern for an entity bean

ibm.com/redbooks