Deallocating Unused JDBC Connections

By default, the ActiveMatrix platform validates a JDBC connection before executing a SQL statement over that connection. On large systems this validation can have a significant performance impact, and a performance benefit can be obtained by deallocating any unused connections.

To deallocate unused connections make the following configuration changes to only those JDBC resource templates that have been configured for XA transaction co-ordination (see JDBC Resources):

Procedure

  1. In ActiveMatrixAdministrator, select Shared Objects > Resource Templates
  2. Select in turn each of the JDBC resource templates that is identified in the Description column as an XA DataSource.
  3. Select the Advanced tab.
  4. Under Host Type Properties, set POOL_IDLE_TIMEOUT to a suitable low value, such as 1 (meaning one minute).
  5. Set POOL_MIN_SIZE to 0.
  6. Click Save.

Result

This procedure internally deallocates any connection that has been idle for more than one minute. This should be quicker than any firewall or database setting, so it should never result in any invalid connections. However if your connection pool does often have one-minute gaps in activity, this will result in a lot of connection allocation/deallocation overhead. You may need to experiment wtih suitable values.