Distributed database middleware solution method
A solution, database technology, applied in the field of computer databases, can solve problems such as high access costs, inability to cope with high concurrency of the Internet or long transaction scenarios of complex systems, and achieve the effect of ensuring strong consistency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment approach
[0075] The implementation method of the present invention based on the XA two-stage transaction is as follows:
[0076] S101: start the global transaction;
[0077] When receiving set autoCommit=0 from the access terminal, XADCSTransactionManager will call the specific XA transaction manager to start the XA global transaction and mark it in the form of XID;
[0078] S102: Execute real sharding SQL;
[0079] After XADCSTransactionManager registers the XAResource corresponding to the database connection into the current XA transaction, the transaction manager sends the XAResource.start command to the database at this stage; all SQL operations before the database receives the XAResource.end command are marked as XA transactions;
[0080] E.g:
[0081] XAResource1.start##Enlist stage execution
[0082] statement.execute("sql1"); ##Simulate the execution of a fragmented SQL1
[0083] statement.execute("sql2"); ##Simulate the execution of a fragmented SQL2
[0084] XAResource1....
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


