public class SimpleJDBCConnectionPool extends Object implements JDBCConnectionPool
| Constructor and Description |
|---|
SimpleJDBCConnectionPool(String driverName,
String connectionUri,
String userName,
String password) |
SimpleJDBCConnectionPool(String driverName,
String connectionUri,
String userName,
String password,
int initialConnections,
int maxConnections) |
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Destroys the connection pool: close() is called an all the connections in
the pool, whether available or reserved.
|
void |
releaseConnection(Connection conn)
Releases a connection that was retrieved earlier.
|
Connection |
reserveConnection()
Retrieves a connection.
|
public SimpleJDBCConnectionPool(String driverName, String connectionUri, String userName, String password) throws SQLException
SQLExceptionpublic SimpleJDBCConnectionPool(String driverName, String connectionUri, String userName, String password, int initialConnections, int maxConnections) throws SQLException
SQLExceptionpublic Connection reserveConnection() throws SQLException
JDBCConnectionPoolreserveConnection in interface JDBCConnectionPoolSQLExceptionpublic void releaseConnection(Connection conn)
JDBCConnectionPoolreleaseConnection in interface JDBCConnectionPoolconn - Connection to be releasedpublic void destroy()
JDBCConnectionPooldestroy in interface JDBCConnectionPoolCopyright © 2023 Vaadin Ltd. All rights reserved.