Class ConnectionFactory
java.lang.Object
com.baomidou.dynamic.datasource.tx.ConnectionFactory
- Author:
- funkye zp
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidcreateSavepoint(String xid) Whether there is a savepointstatic ConnectionProxygetConnection(String xid, String ds) getConnectionstatic booleanhasSavepoint(String xid) Determine whether there is a savepointstatic voidWhether there is a savepointstatic voidputConnection(String xid, String ds, ConnectionProxy connection) put connection
-
Constructor Details
-
ConnectionFactory
public ConnectionFactory()
-
-
Method Details
-
putConnection
put connection- Parameters:
xid- xidds- dsconnection- connection
-
getConnection
getConnection- Parameters:
xid- 事务IDds- ds- Returns:
- boolean
-
notify
Whether there is a savepoint- Parameters:
xid- xidstate- state- Throws:
Exception- Exception
-
createSavepoint
public static void createSavepoint(String xid) throws org.springframework.transaction.TransactionException Whether there is a savepoint- Parameters:
xid- 事务ID- Throws:
org.springframework.transaction.TransactionException- TransactionException
-
hasSavepoint
Determine whether there is a savepoint- Parameters:
xid- 事务ID- Returns:
- true or false
-