public class ContextualJdbcConnectionAccess extends Object implements JdbcConnectionAccess, Serializable
| Constructor and Description |
|---|
ContextualJdbcConnectionAccess(String tenantIdentifier,
SessionEventListener listener,
MultiTenantConnectionProvider connectionProvider) |
| Modifier and Type | Method and Description |
|---|---|
Connection |
obtainConnection()
Obtain a JDBC connection
|
void |
releaseConnection(Connection connection)
Release a previously obtained connection
|
boolean |
supportsAggressiveRelease()
Does the underlying provider of connections support aggressive releasing of connections (and re-acquisition
of those connections later, if need be) in JTA environments?
|
public ContextualJdbcConnectionAccess(String tenantIdentifier, SessionEventListener listener, MultiTenantConnectionProvider connectionProvider)
public Connection obtainConnection() throws SQLException
JdbcConnectionAccessobtainConnection in interface JdbcConnectionAccessSQLException - Indicates a problem getting the connectionpublic void releaseConnection(Connection connection) throws SQLException
JdbcConnectionAccessreleaseConnection in interface JdbcConnectionAccessconnection - The connection to releaseSQLException - Indicates a problem releasing the connectionpublic boolean supportsAggressiveRelease()
JdbcConnectionAccesssupportsAggressiveRelease in interface JdbcConnectionAccessConnectionProvider.supportsAggressiveRelease(),
MultiTenantConnectionProvider.supportsAggressiveRelease()Copyright © 2019 JBoss by Red Hat. All rights reserved.