开发者社区 > 云原生 > 中间件 > 正文

Seate中Could not found global transaction xid = %s,

Seate中Could not found global transaction xid = %s, may be has finished?

展开
收起
fuxixi 2022-07-01 15:03:54 2331 0
1 条回答
写回答
取消 提交回答
  • 举例说明:

    @GlobalTransactional(timeout=60000) public void A(){
    call remoting B();//远程调用B服务 local DB operation;
    }
    public void B(){
    }
    
    

    可能原因: A 执行的总体时间超过了60000ms,导致全局事务发起了全局回滚,此时A或B方法继续执行DB操作,校验全局事务状态,发现全局事务已经回滚。 B服务执行超出其设定的readTimeout 返回异常给A并将异常抛出导致全局事务回滚,此时B服务执行DB操作时,校验全局事务状态,发现全局事务已经回滚。 影响:出现这种情况时,数据会整体回滚至A方法执行前的数据的初态,从数据一致性的视角上看,数据是整体一致的。 此答案整理自钉钉群“3群-Seata 开源讨论群”

    2022-07-01 15:36:06
    赞同 展开评论 打赏
问答地址:

为企业提供高效、稳定、易扩展的中间件产品。

相关电子书

更多
Froma single droplet toafull b 立即下载
Borgaonkar-New-Adventures-In-Spying-3G-And-4G-Users-Locate-Track-And-Monitor 立即下载
Dynamic DDL Adding Structure t 立即下载