You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/11/01 09:35:17 UTC

[GitHub] [shardingsphere] zhfeng commented on a change in pull request #13187: support XA transaction for proxy #12771

zhfeng commented on a change in pull request #13187:
URL: https://github.com/apache/shardingsphere/pull/13187#discussion_r740070976



##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLTCLStatementSQLVisitor.java
##########
@@ -98,7 +108,32 @@ public ASTNode visitSavepoint(final SavepointContext ctx) {
     }
     
     @Override
-    public ASTNode visitXa(final XaContext ctx) {
-        return new MySQLXAStatement();
+    public ASTNode visitXaBegin(final XaBeginContext ctx) {
+        return new MySQLXABeginStatement();

Review comment:
       yeah, because the JTA and XA are different protocol.
   
   - JTA is the API used between the Application (AP) and Transaction Manager (TM) .
   - XA is used between Transaction Manager (TM) and Resource Manager (RM) (such as database, message broker, ...) to coordinate during the 2PC commit.
   
   So we can not use JTA here to handle the XA statments




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org