You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@seata.apache.org by "gitHubYi (via GitHub)" <gi...@apache.org> on 2024/08/07 10:06:43 UTC

[I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

gitHubYi opened a new issue, #6738:
URL: https://github.com/apache/incubator-seata/issues/6738

   ### Ⅰ. Issue Description
   同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚。请问下为啥回滚不是逆序的?
   
   ### Ⅱ. Describe what happened
   客户端日志:
   2024-08-07 17:54:35,146 [/] [NettyClientSelector_RMROLE_1_1] DEBUG i.s.c.r.netty.AbstractNettyRemoting - io.seata.core.rpc.netty.RmNettyRemotingClient@28a852b7 msgId:13, body:BranchRollbackRequest{xid='10.8.99.243:8091:4477129246364476175', branchId=4477129246364476177, branchType=AT, resourceId='xxx', applicationData='{"autoCommit":false}'}
   2024-08-07 17:54:35,146 [/] [rpcDispatch_RMROLE_1_2_40] INFO  i.s.c.r.p.c.RmBranchRollbackProcessor - rm handle branch rollback process:BranchRollbackRequest{xid='10.8.99.243:8091:4477129246364476175', branchId=4477129246364476177, branchType=AT, resourceId='xxxxx', applicationData='{"autoCommit":false}'}
   2024-08-07 17:54:35,147 [/] [rpcDispatch_RMROLE_1_2_40] INFO  io.seata.rm.AbstractRMHandler - Branch Rollbacking: 10.8.99.243:8091:4477129246364476175 4477129246364476177 xxxx
   2024-08-07 17:54:35,215 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG c.a.druid.pool.PreparedStatementPool - {conn-10011, pstmt-20044} exit cache
   2024-08-07 17:54:35,215 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG c.a.druid.pool.PreparedStatementPool - {conn-10011, pstmt-20068} enter cache
   2024-08-07 17:54:35,215 [/] [rpcDispatch_RMROLE_1_2_40] INFO  i.s.r.d.undo.AbstractUndoExecutor - Field not equals, name updateUser, old value xxxx, new value xxxx
   2024-08-07 17:54:35,216 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG i.s.r.d.undo.AbstractUndoExecutor - check dirty data failed, old and new data are not equal, tableName:[xxxx],oldRows:xxxx
   2024-08-07 17:54:35,224 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG c.a.druid.pool.PreparedStatementPool - {conn-10011, pstmt-20045} exit cache
   2024-08-07 17:54:35,225 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG c.a.druid.pool.PreparedStatementPool - {conn-10011, pstmt-20067} enter cache
   2024-08-07 17:54:35,232 [/] [rpcDispatch_RMROLE_1_2_40] ERROR i.s.rm.datasource.DataSourceManager - branchRollback failed. branchType:[AT], xid:[10.8.99.243:8091:4477129246364476175], branchId:[4477129246364476177], resourceId:[xxx], applicationData:[{"autoCommit":false}]. reason:[Branch session rollback failed because of dirty undo log, please delete the relevant undolog after manually calibrating the data. xid = 10.8.99.243:8091:4477129246364476175 branchId = 4477129246364476177]
   2024-08-07 17:54:35,233 [/] [rpcDispatch_RMROLE_1_2_40] INFO  io.seata.rm.AbstractRMHandler - Branch Rollbacked result: PhaseTwo_RollbackFailed_Unretryable
   2024-08-07 17:54:35,233 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG i.s.c.r.p.c.RmBranchRollbackProcessor - branch rollback result:BranchRollbackResponse{xid='10.8.99.243:8091:4477129246364476175', branchId=4477129246364476177, branchStatus=PhaseTwo_RollbackFailed_Unretryable, resultCode=Success, msg='null'}
   2024-08-07 17:54:35,233 [/] [rpcDispatch_RMROLE_1_2_40] DEBUG i.s.c.r.netty.AbstractNettyRemoting - write message:BranchRollbackResponse{xid='10.8.99.243:8091:4477129246364476175', branchId=4477129246364476177, branchStatus=PhaseTwo_RollbackFailed_Unretryable, resultCode=Success, msg='null'}, channel:[id: 0xc3d0ee0a, L:/127.0.0.1:50540 - R:/127.0.0.1:8091],active?true,writable?true,isopen?true
   
   undo_log
   ![image](https://github.com/user-attachments/assets/dcdf3021-8708-420d-8ed8-cbef2d1b9048)
   
   branch_table
   ![image](https://github.com/user-attachments/assets/4dc13d7d-a237-4d45-b5c5-bdee5cddbb0d)
   
   
   - JDK version(e.g. `java -version`): 1.8
   - Seata client/server version:  2.0
   - Database version: mysql 5.7
   - OS(e.g. `uname -a`):
   - Others:


-- 
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@seata.apache.org.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "gitHubYi (via GitHub)" <gi...@apache.org>.
gitHubYi commented on issue #6738:
URL: https://github.com/apache/incubator-seata/issues/6738#issuecomment-2274729645

   我刚测试了这种场景,不是同一个资源,多个本地事务也不是逆序回滚的


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "funky-eyes (via GitHub)" <gi...@apache.org>.
funky-eyes commented on issue #6738:
URL: https://github.com/apache/incubator-seata/issues/6738#issuecomment-2274685799

   纯粹是2.0有bug的原因
   It's purely because of the bug in 2.0.


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "gitHubYi (via GitHub)" <gi...@apache.org>.
gitHubYi closed issue #6738: 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚
URL: https://github.com/apache/incubator-seata/issues/6738


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "funky-eyes (via GitHub)" <gi...@apache.org>.
funky-eyes commented on issue #6738:
URL: https://github.com/apache/incubator-seata/issues/6738#issuecomment-2275053207

   > 请问下回滚不是逆序的原因是bug导致,还是正常情况下也是顺序回滚
   
   bug原因,本来就应该倒序回滚的,你可以将server降级至1.8


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "gitHubYi (via GitHub)" <gi...@apache.org>.
gitHubYi commented on issue #6738:
URL: https://github.com/apache/incubator-seata/issues/6738#issuecomment-2274726877

   请问下回滚不是逆序的原因是bug导致,还是正常情况下也是顺序回滚


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org


Re: [I] 同一个全局事务下多个本地事务修改同一条数据,异常回滚,回滚顺序不是逆序的,导致check dirty data failed,无法回滚 [incubator-seata]

Posted by "funky-eyes (via GitHub)" <gi...@apache.org>.
funky-eyes commented on issue #6738:
URL: https://github.com/apache/incubator-seata/issues/6738#issuecomment-2274687110

   我建议你减少资源重入场景,或者将资源重入的事务归为一个本地事务,而不是多个本地事务,可以临时解决相关问题
   I suggest you reduce resource reentry scenarios, or group resource reentry transactions into one local transaction instead of multiple local transactions, which can temporarily solve related problems


-- 
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@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@seata.apache.org
For additional commands, e-mail: notifications-help@seata.apache.org