Source:
protected synchronized final void phase2Commit (boolean reportHeuristics) throws Error { if (tsLogger.logger.isTraceEnabled()) { tsLogger.logger.trace("BasicAction::phase2Commit() for action-id " + get_uid()); } if ((pendingList != null) && (pendingList.size() > 0)) { int size = ((pendingList == null) ? 0 : pendingList.size()); tsLogger.i18NLogger.warn_coordinator_BasicAction_42(get_uid(), Integer.toString(size), pendingList.toString()); phase2Abort(reportHeuristics); } else if ((preparedList == null || preparedList.size() == 0) && actionStatus == ActionStatus.ABORTED) { phase2Abort(reportHeuristics); } else { Long startTime = TxStats.enabled() ? System.nanoTime() : null; criticalStart(); actionStatus = ActionStatus.COMMITTING; doCommit(preparedList, reportHeuristics); if (heuristicDecision != TwoPhaseOutcome.PREPARE_OK) { if (heuristicDecision == TwoPhaseOutcome.HEURISTIC_COMMIT) heuristicDecision = TwoPhaseOutcome.FINISH_OK; } if ((readonlyList != null) && (readonlyList.size() > 0)) { if (!TxControl.readonlyOptimisation) { if (readonlyList != null) doCommit(readonlyList, reportHeuristics); } while (((recordBeingHandled = readonlyList.getFront()) != null)) { if ((actionType == ActionType.NESTED) && (recordBeingHandled.propagateOnCommit())) { merge(recordBeingHandled); } else { recordBeingHandled = null; } } } forgetHeuristics(); actionStatus = ActionStatus.COMMITTED; updateState(); ActionManager.manager().remove(get_uid()); criticalEnd(); if (TxStats.enabled()) { if (heuristicDecision != TwoPhaseOutcome.HEURISTIC_ROLLBACK) { if (startTime == null) TxStats.getInstance().incrementCommittedTransactions(0L); else TxStats.getInstance().incrementCommittedTransactions(System.nanoTime() - startTime); } } } }

Target:
protected synchronized final void phase2Commit (boolean reportHeuristics) throws Error { if (tsLogger.logger.isTraceEnabled()) { tsLogger.logger.trace("BasicAction::phase2Commit() for action-id " + get_uid()); } if ((pendingList != null) && (pendingList.size() > 0)) { int size = ((pendingList == null) ? 0 : pendingList.size()); tsLogger.i18NLogger.warn_coordinator_BasicAction_42(get_uid(), Integer.toString(size), pendingList.toString()); phase2Abort(reportHeuristics); } else { Long startTime = TxStats.enabled() ? System.nanoTime() : null; criticalStart(); actionStatus = ActionStatus.COMMITTING; doCommit(preparedList, reportHeuristics); if (heuristicDecision != TwoPhaseOutcome.PREPARE_OK) { if (heuristicDecision == TwoPhaseOutcome.HEURISTIC_COMMIT) heuristicDecision = TwoPhaseOutcome.FINISH_OK; } if ((readonlyList != null) && (readonlyList.size() > 0)) { if (!TxControl.readonlyOptimisation) { if (readonlyList != null) doCommit(readonlyList, reportHeuristics); } while (((recordBeingHandled = readonlyList.getFront()) != null)) { if ((actionType == ActionType.NESTED) && (recordBeingHandled.propagateOnCommit())) { merge(recordBeingHandled); } else { recordBeingHandled = null; } } } forgetHeuristics(); actionStatus = ActionStatus.COMMITTED; updateState(); ActionManager.manager().remove(get_uid()); criticalEnd(); if (TxStats.enabled()) { if (heuristicDecision != TwoPhaseOutcome.HEURISTIC_ROLLBACK) { if (startTime == null) TxStats.getInstance().incrementCommittedTransactions(0L); else TxStats.getInstance().incrementCommittedTransactions(System.nanoTime() - startTime); } } } }