The Java 2 Platform, Enterprise Edition provides containers for client applications, web components (based on Servlets and JavaServer Pages ) and Enterprise JavaBeans components. These containers provide deployment and runtime support for application components. They also provide a federated view of the services provided by the underlying application server for the application components.
Containers run on existing systems: web servers for the web containers, application servers, transaction processing (TP) monitors, and database systems for EJB containers. This enables enterprises to leverage both the advantages of their existing systems and those with J2EE technology. Enterprises can write (or rewrite) new applications using J2EE capabilities and can also encapsulate parts of existing applications with Enterprise JavaBeans (EJB ) or JavaServer Pages (JSP ) technologies.
Enterprise applications access functions and data associated with applications running on EISs. Application servers extend their containers and support connectivity to heterogeneous EISs. Enterprise tools and Enterprise Application Integration (EAI) vendors add value by providing tools and frameworks to simplify the EIS integration task.
The J2EE Connector architecture defines a standard architecture for connecting the J2EE platform to heterogeneous EISs. Examples of EISs include ERP, mainframe transaction processing, database systems, and legacy applications not written in the Java programming language. By defining a a set of scalable, secure, and transactional mechanisms, the J2EE Connector architecture enables the integration of EISs with application servers and enterprise applications.
The J2EE Connector architecture enables an EIS vendor to provide a standard resource adapter for its EIS. The resource adapter plugs into an application server, providing connectivity between the EIS, the application server, and the enterprise application. If an application server vendor has extended its system to support the J2EE Connector architecture, it is assured of seamless connectivity to multiple EISs. An EIS vendor needs to provide just one standard resource adapter which has the capability to plug in to any application server that supports the J2EE Connector architecture.
Multiple resource adapters (that is, one resource adapter per type of EIS) are pluggable into an application server. This capability enables application components deployed on the application server to access the underlying EISs.
The following diagram illustrates the J2EE Connector architecture.
To achieve a standard system-level pluggability between application servers and EISs, the J2EE Connector architecture defines a standard set of system-level contracts between an application server and EIS. The resource adapter implements the EIS-side of these system-level contracts.
A resource adapter is a system-level software driver used by an application server or an application client to connect to an EIS. By plugging into an application server, the resource adapter collaborates with the server to provide the underlying mechanisms, the transactions, security, and connection pooling mechanisms. A resource adapter is used within the address space of the application server.
An application server and an EIS collaborate to keep all system-level mechanisms, such as transactions, security, and connection management, transparent from the application components. As a result, an application component provider focuses on the development of business and presentation logic for its application components and need not get involved in the system-level issues related to EIS integration. This promotes easier and faster development of scalable, secure, and transactional enterprise applications that require connectivity with multiple EISs.
The J2EE Connector architecture (Version 1.0) defines the following set of system-level contracts between an application server and EIS, which enables outbound connectivity to an EIS:
A Connection Management contract that lets an application server pool connections to an underlying EIS, and lets application components connect to an EIS. This leads to a scalable application environment that can support a large number of clients requiring access to EISs
A Transaction Management contract between the transaction manager and an EIS that supports transactional access to EIS resource managers. This contract lets an application server use a transaction manager to manage transactions across multiple resource managers. This contract also supports transactions that are managed internal to an EIS resource manager without the necessity of involving an external transaction manager.
A Security contract that enables a secure access to an EIS. This contract provides support for a secure application environment, which reduces security threats to the EIS and protects valuable information resources managed by the EIS.
The J2EE Connector architecture (Version 1.5) defines the following set of system-level contracts between an application server and EIS, which enables inbound connectivity from an EIS:
A Transaction Inflow contract that allows a resource adapter to propagate an imported transaction to an application server. This contract also allows a resource adapter to flowin transaction completion and crash recovery calls initiated by an EIS, and ensures that the ACID properties of the imported transaction are preserved.
A Message Inflow contract that allows a resource adapter to asynchronously deliver messages to message endpoints residing in the application server independent of the specific messaging style, messaging semantics and messaging infrastructure used to deliver messages. This contract also serves as the standard message provider pluggability contract that allows a wide range of message providers (Java Message Service (JMS), Java API for XML Messaging (JAXM), etc.) to be plugged into any J2EE compatible application server via a resource adapter.
The J2EE Connector architecture (Version 1.5) also defines the following set of system-level contracts between an application server and EIS, which enables resource adapter lifecycle management and thread management:
A Lifecycle Management contract that allows an application server to manage the lifecycle of a resource adapter. This contract provides a mechanism for the application server to bootstrap a resource adapter instance during its deployment or application server startup, and to notify the resource adapter instance during its undeployment or during an orderly shutdown of the application server.
A Work Management contract that allows a resource adapter to do work (monitor network endpoints, call application components, etc.) by submitting Work instances to an application server for execution. The application server dispatches threads to execute submitted Work instances. This allows a resource adapter to avoid creating or managing threads directly, provides a mechanism for a resource adapter to do its work, and allows an application server to efficiently pool threads and have more control over its runtime environment. The resource adapter can control the security context and transaction context with which Work instances are executed.
The J2EE Connector architecture also defines a Common Client Interface (CCI) for EIS access. The CCI defines a standard client API for application components. The CCI enables application components and Enterprise Application Integration (EAI) frameworks to drive interactions across heterogeneous EISs using a common client API.
The CCI is intended for use by Enterprise Application Integration (EAI) and enterprise tools vendors.
The J2EE Connector Architecture Specification has been developed under the Java Community Process . The Java Specification Request (JSR) for the J2EE Connector Architecture has 24 expert group members. The expert group includes leading application server vendors, EIS vendors, messaging system vendors and enterprise tool vendors. Please send comments on the J2EE Connector Architecture Specification to: firstname.lastname@example.org