远程事务没有回滚
- 主要言語
- Java
- スター
- 4.2k
- フォーク
- 1.4k
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
大神,请教一个问题,先调用远程事务,远程事务正确,再调用本地事务,本地事务报错,能回滚,远程事务不回滚,怎么处理?
本地事务代码如下:
@LcnTransaction(propagation = DTXPropagation.REQUIRED)
@Transactional//事务注解
public ReturnMap save(HttpServletRequest request, HttpServletResponse response,TeacherAttrBean teacherAttrBean){
JSONObject jsonObject = JSONObject.fromObject(sysFegin.saveUserInfo(teacherAttrBean));
System.out.println(1/0); // 抛出异常
}
// 远程事务
@TccTransaction(propagation = DTXPropagation.SUPPORTS)
@Transactional
public ReturnMap saveUser(HttpServletRequest request, HttpServletResponse response,UserBean userBean) {
// 插入数据库 代码省略
return ok
}
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
調査の方向性
Start with the `save` and `saveUser` entry points shown in the issue, focusing on their `@LcnTransaction`, `@TccTransaction`, and `@Transactional` annotations. Reproduce the remote call followed by the local `1/0` exception, then read the transaction propagation and rollback documentation or tests; done means the expected rollback behavior and configuration are clearly established.
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- backend, distributed-systems
- issue の種類
- バグ
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 15/100