LOG.debug("Prepare: " + xid);
}
// We allow interleaving multiple transactions, so
// we don't limit prepare to the associated xid.
XATransactionId x;
// THIS SHOULD NEVER HAPPEN because end(xid, TMSUCCESS) should have been
// called first
if (xid == null || (equals(associatedXid, xid))) {
throw new XAException(XAException.XAER_PROTO);
} else {
// TODO: cache the known xids so we don't keep recreating this one??
x = new XATransactionId(xid);
}
try {
TransactionInfo info = new TransactionInfo(getConnectionId(), x, TransactionInfo.PREPARE);