<database name='jdbc/test'> <init> <driver>postgresql.Driver</driver> <url>jdbc:postgresql://localhost/test</url> <user>ferg</user> <password>foobar</password> </init> </database> getMaxConnection connections are already active, getPooledConnection will block waiting for an available connection. The wait is timed. If connection-wait-time passes and there is still no connection, getPooledConnection create a new connection anyway. Connections will only stay in the pool for about 5 seconds. After that they will be removed and closed. This reduces the load on the DB and also protects against the database dropping old connections.
| |