This is an automated email from the ASF dual-hosted git repository.
liaoxin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new c87180a3e43 [fix](cloud) fix abort transaction in runningTxns list
when show routine load (#45629)
c87180a3e43 is described below
commit c87180a3e430df3f43cf734e88b04ab1aa55b3cd
Author: hui lai <[email protected]>
AuthorDate: Fri Dec 20 15:27:46 2024 +0800
[fix](cloud) fix abort transaction in runningTxns list when show routine
load (#45629)
There are some abort transaction in running transaction list when
execute `Show routine load`:
```
statistic:
{"receivedBytes":690347731,"runningTxns":[84983868539904,85435786230784,85005343163392,85437129268225,85454778056704,85435116123136,85025611246592,85437060583424,85434241746944,85415318736896,85465045433344,84985143969794,85004337471488,85415183878144,85415385197568,85424109151232,85004808868865,85005412474880,85025545732096,85414981022720,84984677082113,85436924459012],"errorRows":0,"committedTaskNum":211,"loadedRows":3612290,"loadRowsRate":195026,"abortedTaskNum":1,"error
[...]
```
When abort transaction to meta service, transaction info in
`abortTxnResponse `would be default value when abort transaction
failed.Then this logic will invalid for transaction id is default value:
```
this.jobStatistic.runningTxnIds.remove(txnState.getTransactionId());
```
---
.../org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java | 1 +
1 file changed, 1 insertion(+)
diff --git
a/fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java
b/fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java
index 11a3f05ead7..b9425245f42 100644
---
a/fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java
+++
b/fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java
@@ -1288,6 +1288,7 @@ public class CloudGlobalTransactionMgr implements
GlobalTransactionMgrIface {
if (txnCommitAttachment != null && txnCommitAttachment instanceof
RLTaskTxnCommitAttachment) {
RLTaskTxnCommitAttachment rlTaskTxnCommitAttachment =
(RLTaskTxnCommitAttachment) txnCommitAttachment;
callbackId = rlTaskTxnCommitAttachment.getJobId();
+ txnState.setTransactionId(transactionId);
}
cb = callbackFactory.getCallback(callbackId);
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]