if ((getTransaction() != null) &&
getTransaction().isOpen() &&
getTransaction().getAssociatedDatabase().equals(this))
{
String txStatus = TxUtil.getStatusString(getTransaction().getStatus());
TransactionInProgressException ex = new TransactionInProgressException(
"Database cannot be closed, associated Tx is still open." +
" Transaction status is '" + txStatus + "'." +
" Used PBKey was "+getTransaction().getBroker().getPBKey());
log.error(ex);
throw ex;