try {
ManagedConnectionInfo mci = connectionInfo.getManagedConnectionInfo();
TransactionContext transactionContext = transactionContextManager.getContext();
if (transactionContext != null && transactionContext.isInheritable() && transactionContext.isActive()) {
XAResource xares = mci.getXAResource();
transactionContext.enlistResource(xares);
}
} catch (SystemException e) {
returnConnection(connectionInfo, ConnectionReturnAction.DESTROY);
throw new ResourceException("Could not get transaction", e);
} catch (RollbackException e) {