--repeat;
Thread.sleep(PAUSE_TIME_BEFORE_REPEAT_FOR_LOCK_ACQUISITION_TIMEOUT);
continue;
} catch (IllegalStateException err) {
// Not associated with a txn??
throw new SystemFailureException(err);
} catch (IllegalArgumentException err) {
// Not associated with a txn??
throw new SystemFailureException(err);
} catch (Exception e) {
LOGGER.debug(e, "Error while attempting to save");
// Some error occurred (likely within our code) ...
txn.rollback();
throw e;
}
LOGGER.debug("Altered {0} node(s)", numNodes);
// Commit the transaction ...
txn.commit();
if (LOGGER.isDebugEnabled()) {
LOGGER.debug("Altered {0} keys: {1}", numNodes, this.changedNodes.keySet());
}
this.clearState();
that.clearState();
} catch (NotSupportedException err) {
// No nested transactions are supported ...
return;
} catch (SecurityException err) {
// No privilege to commit ...
throw new SystemFailureException(err);
} catch (IllegalStateException err) {
// Not associated with a txn??
throw new SystemFailureException(err);
} catch (RollbackException err) {
// Couldn't be committed, but the txn is already rolled back ...
return;
} catch (HeuristicMixedException err) {
} catch (HeuristicRollbackException err) {
// Rollback has occurred ...
return;
} catch (SystemException err) {
// System failed unexpectedly ...
throw new SystemFailureException(err);
}
// If we've made it this far, we should never repeat ...
break;
}