This is an automated email from the ASF dual-hosted git repository. kxiao pushed a commit to branch branch-2.0-beta in repository https://gitbox.apache.org/repos/asf/doris.git
commit 56f0010a3b3aba30b2a03734584055e51d350b10 Author: GoGoWen <82132356+gogo...@users.noreply.github.com> AuthorDate: Fri Jun 9 09:33:58 2023 +0800 [Fix](2PC) fix timeout config is not avaible for commit phase in 2pc (#20423) fix config::txn_commit_rpc_timeout_ms is not available for commit phase in 2pc. --- .../src/main/java/org/apache/doris/service/FrontendServiceImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/service/FrontendServiceImpl.java b/fe/fe-core/src/main/java/org/apache/doris/service/FrontendServiceImpl.java index 2dbb007498..baaa679ffd 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/service/FrontendServiceImpl.java +++ b/fe/fe-core/src/main/java/org/apache/doris/service/FrontendServiceImpl.java @@ -1237,8 +1237,9 @@ public class FrontendServiceImpl implements FrontendService.Iface { } if (txnOperation.equalsIgnoreCase("commit")) { + long timeoutMs = request.isSetThriftRpcTimeoutMs() ? request.getThriftRpcTimeoutMs() / 2 : 5000; Env.getCurrentGlobalTransactionMgr() - .commitTransaction2PC(database, tableList, request.getTxnId(), 5000); + .commitTransaction2PC(database, tableList, request.getTxnId(), timeoutMs); } else if (txnOperation.equalsIgnoreCase("abort")) { Env.getCurrentGlobalTransactionMgr().abortTransaction2PC(database.getId(), request.getTxnId(), tableList); } else { --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org