Neoview ODBC Drivers Manual (R2.2 SP1)

Table Of Contents
Client Data Sources
Client data sources reside on a client workstation. Each client data source is a logical name that
identifies the attribute values used to connect to NDCS and defines some local behavior for the
connection.
Use the Microsoft ODBC Administrator to add, configure, and remove the HP Neoview ODBC
driver data sources.
NOTE: If an ODBC client tries to connect to a server data source that is stopped, NDCS rejects
the connection.
Connections
Connecting a Client to a Data Source
The following scenario describes how an ODBC client application connects to NDCS:
1. The application connects using the client data source name. The client source data specifies
an IP address or host name and port number.
2. If the user information is not valid, the connection is rejected.
Connection Pooling
Connection pooling enables an application to use a connection from a pool of connections that
do not need to be reestablished for each use. Once a connection has been created and placed in
a pool, an application can reuse that connection without performing the complete connection
process.
Using a pooled connection can result in significant performance gains, because applications can
save the overhead involved in making a connection. This can be particularly significant for
middle-tier applications that connect over a network, or for applications that repeatedly connect
and disconnect, such as Internet applications.
In addition to performance gains, the connection pooling architecture enables an environment
and its associated connections to be used by multiple components in a single process. This means
that stand-alone components in the same process can interact with each other without being
aware of each other. A connection in a connection pool can be used repeatedly by multiple
components.
NOTE: Connection pooling can be used by an ODBC application exhibiting ODBC 2.x behavior,
as long as the application can call SQLSetEnvAttr. When using connection pooling, the application
must not execute SQL statements that change the database or the context of the database, such
as changing the database name, which changes the catalog used by a data source.
The connection pool is maintained by the Driver Manager. Connections are drawn from the pool
when the application calls SQLConnect or SQLDriverConnect, and are returned to the pool when
the application calls SQLDisconnect. The size of the pool grows dynamically based upon the
requested resource allocations. It shrinks based on the inactivity timeout: If a connection is
inactive for a period of time (it has not been used in a connection), it is removed from the pool.
The size of the pool is limited only by memory constraints and limits on the server.
The Driver Manager determines whether a specific connection in a pool should be used according
to the arguments passed in SQLConnect or SQLDriverConnect, and the connection attributes
set after the connection was allocated.
When the Driver Manager is pooling connections, it needs to be able to determine if a connection
is still working before handing the connection out. Otherwise, the Driver Manager keeps on
handing out the dead connection to the application whenever a transient network failure occurs.
In ODBC 3.5 a new connection attribute, SQL_ATTR_CONNECTION_DEAD, has been defined.
16 HP Neoview ODBC Driver Overview for Windows