This is an automated email from the ASF dual-hosted git repository.
dataroaring 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 8e17d5907fc [Fix](group commit) Fix group commit forward required
param fault (#38265)
8e17d5907fc is described below
commit 8e17d5907fc479a07eb1596a42f584c1a6c09ab1
Author: abmdocrt <[email protected]>
AuthorDate: Wed Jul 24 18:05:08 2024 +0800
[Fix](group commit) Fix group commit forward required param fault (#38265)
## Proposed changes
<!--Describe your changes.-->
The error message is:
2024-07-23 17:30:09.300 INFO [suite-thread-1]
(StreamLoadAction.groovy:201) - Stream load elapsed 2050 ms, is http
stream: true, response: nulljava.lang.IllegalStateException: Expect
frontend stream load response code is 307, but meet 200
body: {"status":"FAILED","msg":"errCode = 2, detailMessage = Required
field 'user' was not present! Struct: TMasterOpRequest(user:null, db:,
sql:, clientNodeHost:172.20.48.85, clientNodePort:9010,
groupCommitInfo:TGroupCommitInfo(getGroupCommitLoadBeId:true,
groupCommitLoadTableId:10321, isCloud:false))"}
The forward param `TMasterOpRequest`(FrontendService.thrift) has a
required field `user`, which get from ConnectContext. So we set
admin_user to ConnectContext to solve this problem.
---
fe/fe-core/src/main/java/org/apache/doris/httpv2/rest/LoadAction.java | 3 +++
1 file changed, 3 insertions(+)
diff --git
a/fe/fe-core/src/main/java/org/apache/doris/httpv2/rest/LoadAction.java
b/fe/fe-core/src/main/java/org/apache/doris/httpv2/rest/LoadAction.java
index 47c495b2913..8bdc88a9c22 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/httpv2/rest/LoadAction.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/httpv2/rest/LoadAction.java
@@ -403,6 +403,9 @@ public class LoadAction extends RestBaseController {
ctx.setEnv(Env.getCurrentEnv());
ctx.setThreadLocalInfo();
ctx.setRemoteIP(request.getRemoteAddr());
+ // We set this variable to fulfill required field 'user' in
+ // TMasterOpRequest(FrontendService.thrift)
+ ctx.setQualifiedUser(Auth.ADMIN_USER);
ctx.setThreadLocalInfo();
try {
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]