public class ConnectionProxy extends AbstractConnectionProxy
| 限定符和类型 | 类和说明 |
|---|---|
static class |
ConnectionProxy.LockRetryPolicy |
| 限定符和类型 | 字段和说明 |
|---|---|
static boolean |
IS_REPORT_SUCCESS_ENABLE |
dataSourceProxy, targetConnection| 构造器和说明 |
|---|
ConnectionProxy(DataSourceProxy dataSourceProxy,
Connection targetConnection)
Instantiates a new Connection proxy.
|
| 限定符和类型 | 方法和说明 |
|---|---|
void |
appendLockKey(String lockKey)
append lockKey
|
void |
appendUndoLog(SQLUndoLog sqlUndoLog)
append sqlUndoLog
|
void |
bind(String xid)
Bind.
|
void |
checkLock(String lockKeys)
Check lock.
|
void |
commit() |
ConnectionContext |
getContext()
Gets context.
|
boolean |
isGlobalLockRequire()
get global lock requires flag
|
boolean |
lockQuery(String lockKeys)
Lock query.
|
void |
rollback() |
void |
setAutoCommit(boolean autoCommit) |
void |
setGlobalLockRequire(boolean isLock)
set global lock requires flag
|
abort, clearWarnings, close, createArrayOf, createBlob, createClob, createNClob, createSQLXML, createStatement, createStatement, createStatement, createStruct, getAutoCommit, getCatalog, getClientInfo, getClientInfo, getDataSourceProxy, getDbType, getHoldability, getMetaData, getNetworkTimeout, getSchema, getTargetConnection, getTransactionIsolation, getTypeMap, getWarnings, isClosed, isReadOnly, isValid, isWrapperFor, nativeSQL, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, releaseSavepoint, rollback, setCatalog, setClientInfo, setClientInfo, setHoldability, setNetworkTimeout, setReadOnly, setSavepoint, setSavepoint, setSchema, setTransactionIsolation, setTypeMap, unwrappublic ConnectionProxy(DataSourceProxy dataSourceProxy, Connection targetConnection)
dataSourceProxy - the data source proxytargetConnection - the target connectionpublic ConnectionContext getContext()
public void bind(String xid)
xid - the xidpublic void setGlobalLockRequire(boolean isLock)
isLock - whether to lockpublic boolean isGlobalLockRequire()
public void checkLock(String lockKeys) throws SQLException
lockKeys - the lockKeysSQLException - the sql exceptionpublic boolean lockQuery(String lockKeys) throws SQLException
lockKeys - the lock keysSQLException - the sql exceptionpublic void appendUndoLog(SQLUndoLog sqlUndoLog)
sqlUndoLog - the sql undo logpublic void appendLockKey(String lockKey)
lockKey - the lock keypublic void commit()
throws SQLException
SQLExceptionpublic void rollback()
throws SQLException
SQLExceptionpublic void setAutoCommit(boolean autoCommit)
throws SQLException
SQLExceptionCopyright © 2020 Seata. All rights reserved.