Databases Reference
In-Depth Information
To determine the optimal setting for the maximum idle time, think about
the slowest time of day for your applications and set this option accordingly.
For example, if in the evening you know that only one or two users are log-
ging into applications every hour or so, you would want to configure this set-
ting to at least 60 minutes. That way, a connection will be waiting in the pool
for your users; a connection will not have to be reestablished, which we know
is performance expensive.
Connection Pool Model for ODBC
Connection pooling in ODBC is provided by the Microsoft ODBC Driver
Manager on Windows platforms, application providers, some database driver
vendors, or not at all. At the time of the publishing of this topic, we know of only
one UNIX implementation of connection pooling for ODBC, and its implemen-
tation is similar to the ADO.NET connection pool model (see “Connection Pool
Model for ADO.NET,” page 230). Also, the implementations of connection pool-
ing available on Windows platforms differ. Some are similar to the ADO.NET
connection pool model.
In this section, we discuss only the model as defined in the ODBC specifica-
tion.
Connection Pooling as Defined in the ODBC Specification
We want to start by saying that the connection pool model in ODBC was defined
before application servers were widely adopted. Application servers allow multi-
ple applications to run in the same process, which makes sharing connection
pools across applications possible. However, the scenario of an application server
for ODBC applications (C/C++ applications) is unlikely.
As stated in the ODBC specification, “The connection pooling architecture
enables an environment and its associated connection to be used by multiple
components in a single process.” 1 An environment is a global context that is used
to access data from an application. In association with connection pooling, an
environment “owns” the connections inside an application. Typically, there is
only one environment within an application, which means that there is usually
one connection pool for one application.
1 Microsoft ODBC 3.0 Programmer's Reference and SDK Guide , Volume I. Redmond: Microsoft Press,
1997.
 
 
Search WWH ::




Custom Search