Connection Pooling (Delegate Drivers tutorial)
When you use pooling, users can connect to any dbExpress connection contained in the pool.
MaxConnections parameter specifies the maximum number of connections allowed and
MinConnections specifies the minimum number of connections allowed. If more than
MaxConnections are required, the call is placed on hold.
To be able to pool the connection activity, you must set the
DelegateConnection parameter of the connection.
The same as for connection tracing, there are several ways to do this:
- Edit the properties of the TSQLConnection component using the Object Inspector.
- Modify the connection using the Data Explorer pane.
- Add the
DelegateConnection=DBXPoolConnectionline to the [DGCONNECTION] section in the dbxconnections.ini file.
The same as for connection tracing, the first possibility, involving the Object Inspector, will be used.
Now go to the DelegateConnection property and set it to DBXPool, using the property's drop-down menu. You will see that DelegateName is automatically set to DBXPool. Change ConnectTimeout, MaxConnection, and MinConnection to the values you need. Now the connection will be pooled.