public final class ConnectionHandler extends Object implements TransactionAware
| Modifier and Type | Class and Description |
|---|---|
static class |
ConnectionHandler.DirtyAttribute |
static class |
ConnectionHandler.State |
TransactionAware.SQLCallable<T>| Constructor and Description |
|---|
ConnectionHandler(XAConnection xaConnection,
Pool pool) |
public ConnectionHandler(XAConnection xaConnection, Pool pool) throws SQLException
SQLExceptionpublic ConnectionWrapper newConnectionWrapper()
public ConnectionWrapper newDetachedConnectionWrapper()
public void onConnectionWrapperClose(ConnectionWrapper wrapper, ConnectionWrapper.JdbcResourcesLeakReport leakReport) throws SQLException
SQLExceptionpublic Connection getConnection()
getConnection in interface TransactionAwarepublic XAResource getXaResource()
public void resetConnection()
throws SQLException
SQLExceptionpublic void closeConnection()
throws SQLException
SQLExceptionpublic boolean setState(ConnectionHandler.State expected, ConnectionHandler.State newState)
public void setState(ConnectionHandler.State newState)
public boolean isActive()
public void touch()
public boolean isLeak(Duration timeout)
public boolean isIdle(Duration timeout)
public void setMaxLifetimeTask(Future<?> maxLifetimeTask)
public Thread getHoldingThread()
public void setHoldingThread(Thread holdingThread)
public void setDirtyAttribute(ConnectionHandler.DirtyAttribute attribute)
public boolean isEnlisted()
public void transactionStart()
throws SQLException
transactionStart in interface TransactionAwareSQLExceptionpublic void transactionCommit()
throws SQLException
transactionCommit in interface TransactionAwareSQLExceptionpublic void transactionRollback()
throws SQLException
transactionRollback in interface TransactionAwareSQLExceptionpublic void transactionEnd()
throws SQLException
transactionEnd in interface TransactionAwareSQLExceptionpublic void transactionCheckCallback(TransactionAware.SQLCallable<Boolean> transactionCheck)
transactionCheckCallback in interface TransactionAwarepublic void deferredEnlistmentCheck()
throws SQLException
SQLExceptionpublic void setFlushOnly()
setFlushOnly in interface TransactionAwarepublic void setFlushOnly(SQLException se)
Copyright © 2020 JBoss by Red Hat. All rights reserved.