Oracle Application Server 10g: J2EE Deployment and Administration

Years ago, when an application needed to talk to a database, it had to open a socket, connect to the database server, and communicate according to some proprietary protocol. All of this connection code polluted the business logic and limited the database portability. Fortunately, Java Database Connectivity (JDBC) now allows you to use a common API to access a great variety of databases. Under the covers, JDBC drivers (or "resource adapters") translate the JDBC calls into database-specific commands.

J2EE Connectors are resource adapters that let you communicate generically with all sorts of external systems, not just databases. Each Connector obeys some application-level client API (like JDBC) and translates those calls to protocols understood by the remote system. The Connector also implements system-level interfaces that let the J2EE container manage connection pooling, transactions, and security. In the end, instead of worrying about how to connect to a remote system, the EJBs and Servlets can just look up a generic connection factory, get a connection, and interact with the system through the client API, as shown in Figure 12-1.

Figure 12-1: J2EE Connector Architecture

The following terms are commonly used when talking about J2EE Connectors:

Категории