/** Verify that the commit conflict string contains customer-friendly * information. Throw an error if a problem is detected. * * @param ex The commit conflict exception. */ public static void checkCommitConflictException(ConflictException ex) { String errStr = ex.toString(); if ((errStr.indexOf("REMOVED") >= 0) || (errStr.indexOf("INVALID") >= 0) || (errStr.indexOf("Deserializ") >= 0)) { throw new TestException("Test got " + errStr + ", but this error text " + "might contain GemFire internal values\n" + TestHelper.getStackTrace(ex)); } // if (errStr.indexOf("from <local invalidated> to <invalidated>") >= 0) { // throw new TestException("Should not get a conflict on a local invalidate becoming an invalidate " + // TestHelper.getStackTrace(ex)); // } }
} catch (ConflictException e) { failedCommit = true; Log.getLogWriter().info("finishTx() caught " + e.toString());
failedCommit = true; TxBB.inc(TxBB.NUM_EXPECTED_FAILED_COMMIT); Log.getLogWriter().info("finishTx() caught " + e.toString());
String errStr = cce.toString(); boolean isCausedByTransactionWriterException = errStr.indexOf("intentionally throw") >= 0; if (isSerialExecution && !isCausedByTransactionWriterException) {