@Test public void testLockRetryPolicyRollbackOnConflict() throws Exception { boolean oldBranchRollbackFlag = (boolean) branchRollbackFlagField.get(null); branchRollbackFlagField.set(null, true); ConnectionProxy connectionProxy = new ConnectionProxy(dataSourceProxy, null); connectionProxy.bind(TEST_XID); Assertions.assertThrows(LockConflictException.class, connectionProxy::commit); branchRollbackFlagField.set(null, oldBranchRollbackFlag); }
public void bind(String xid) { context.bind(xid); }
ConnectionProxy extends AbstractConnectionProxy { public void bind(String xid) { context.bind(xid); } }
ConnectionProxy extends AbstractConnectionProxy { public void bind(String xid) { context.bind(xid); } ConnectionProxy(DataSourceProxy dataSourceProxy, Connection targetConnection); }
ConnectionProxy extends AbstractConnectionProxy { public void bind(String xid) { context.bind(xid); } ConnectionProxy(DataSourceProxy dataSourceProxy, Connection targetConnection); ConnectionContext getContext(); void bind(String xid); void setGlobalLockRequire(boolean isLock); boolean isGlobalLockRequire(); void checkLock(String lockKeys); boolean lockQuery(String lockKeys); void appendUndoLog(SQLUndoLog sqlUndoLog); void appendLockKey(String lockKey); @Override void commit(); @Override void rollback(); @Override void setAutoCommit(boolean autoCommit); }
ConnectionProxy extends AbstractConnectionProxy { public void bind(String xid) { context.bind(xid); } ConnectionProxy(DataSourceProxy dataSourceProxy, Connection targetConnection); ConnectionContext getContext(); void bind(String xid); void setGlobalLockRequire(boolean isLock); boolean isGlobalLockRequire(); void checkLock(String lockKeys); boolean lockQuery(String lockKeys); void appendUndoLog(SQLUndoLog sqlUndoLog); void appendLockKey(String lockKey); @Override void commit(); @Override void rollback(); @Override void setAutoCommit(boolean autoCommit);  }