JDBC Type 4 Driver Programmer's Reference for SQL/MX Release 3.2.1

Figure 2 Type 4 driver—the API layer, IDL layer, and the Transport layer— to the MXCS association
server
Figure 2 (page 20) illustrates the three layers of the Type 4 driver—the API layer, IDL layer, and
the Transport layer— to the MXCS association server.
Data Sources
“JDBC Data Source (client-side)” (page 20)
“MXCS Data Source (server-side)” (page 20)
The term data source logically refers to a database or other data storage entity. In this manual,
two concepts of data source concepts apply:
A JDBC (client) data source, which is physically a Java object that contains properties such
as the URL of the MXCS Association Server, and the catalog and the schema to use to access
the database. The JDBC data source also contains methods for obtaining a JDBC connection
to the underlying database.
An MXCS (server) data source, which is physically a set of information that is created and
managed by MXCS. This data source contains configuration information, which defines the
semantics of MXCS servers created with that server data source.
JDBC Data Source (client-side)
All JDBC data source classes implement either the javax.sql.DataSource interface or the
javax.sql.ConnectionPoolDataSource interface. The Type 4 driver data source classes
are com.tandem.t4jdbc.SQLMXDataSource and com.tandem.t4jdbc.SQLMXDataSource.
(These classes are defined by the JDBC 3.0 specification.) The Type 4 driver implements
javax.sql.XADataSource, java.transaction.xa.XAResource to support distributed
transactions.
Typically, a user or system administrator use a tool to create a data source, and then register the
data source by using a JNDI service provider. At run time, a user application typically retrieves
the data source through JNDI, and uses the data source’s methods to establish a connection to the
underlying database.
A DataSource object maps to an instance of a database. In the Type 4 driver product, the
DataSource object acts as an interface between the application code and the database, and
enables connection with an MXCS data source.
MXCS Data Source (server-side)
Server data sources reside on a NonStop server. Each server data source represents a pool of
SQL MXCS servers that share the same NonStop SQL context. A server data source is typically
created by a NonStop system administrator, who defines the semantics of all connections made
through that server data source. For example, the server data source contains information on how
many MXCS servers can be in its corresponding pool, which defines how many connections can
be handled through this data source.
For information on configuring MXCS XA data source, see the HP NonStop Connectivity Service
Manual for SQL/MX Release 3.2.1.
Security
Clients connect to the MXCS server with a valid Guardian user ID or alias and password, using
standard JDBC 3.0 APIs. An application can make multiple connections to MXCS using different
user IDs, and creating different connection objects.
20 Accessing SQL Databases with SQL/MX