Implementation of the J2EE Connector Architecture (JCA)
JCA is a resource manager integration API whose goal is to standardize
access to non-relational resources in the same way the JDBC API
standardized access to relational data.
The purpose of this notes is
to introduce the utility of the JCA APIs and then describe the
architecture of JCA in JBoss.
J2EE 1.4 contains a connector architecture (JCA) specification that
allows for the integration of transacted and secure resource adaptors
into a J2EE application server environment.
The JCA specification
describes the notion of such resource managers as Enterprise Information
Systems (EIS).
Examples of EIS systems include enterprise resource
planning packages, mainframe transaction processing, non-Java legacy
applications, etc.
The reason for focusing on EIS is primarily because the notions of
transactions, security, and scalability are requirements in enterprise
software systems. However, the JCA is applicable to any resource that
needs to integrate into JBoss in a secure, scalable and transacted
manner.
In this introduction we will focus on resource adapters as a
generic notion rather than something specific to the EIS environment.
The connector architecture defines a standard SPI (Service Provider
Interface) for integrating the transaction, security and connection
management facilities of an application server with those of a resource
manager.
The SPI defines the system level contract between the resource
adaptor and the application server.
The connector architecture also defines a Common Client Interface
(CCI) for accessing resources.
The CCI is targeted at EIS development
tools and other sophisticated users of integrated resources. The CCI
provides a way to minimize the EIS specific code required by such tools.
Typically J2EE developers will access a resource using such a tool, or a
resource specific interface rather than using CCI directly. The reason
is that the CCI is not a type specific API. To be used effectively it
must be used in conjunction with metadata that describes how to map from
the generic CCI API to the resource manager specific data types used
internally by the resource manager.
The purpose of the connector architecture is to enable a resource
vendor to provide a standard adaptor for its product. A resource adaptor
is a system-level software driver that is used by a Java application to
connect to resource.
The resource adaptor plugs into an application
server and provides connectivity between the resource manager, the
application server, and the enterprise application. A resource vendor
need only implement a JCA compliant adaptor once to allow use of the
resource manager in any JCA capable application server.
An application server vendor extends its architecture once to support
the connector architecture and is then assured of seamless connectivity
to multiple resource managers.
Likewise, a resource manager vendor
provides one standard resource adaptor and it has the capability to plug
in to any application server that supports the connector architecture.
The application server is extended to provide support for the JCA SPI
to allow a resource adaptor to integrate with the server connection
pooling, transaction management and security management facilities. This
integration API defines a three-part system contract.
-
Connection management
: a contract that allows the application
server to pool resource connections. The purpose of the pool management
is to allow for scalability. Resource connections are typically expense
objects to create and pooling them allows for more effective reuse and
management.
-
Transaction Management
: a contract that allows the application server transaction manager to manage transactions that engage resource managers.
-
Security Management
: a contract that enables secured access to resource managers.
Nessun commento:
Posta un commento