This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch branch-4.1
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-4.1 by this push:
new 4d0af109574 [branch-4.1][fix](case) Fix profile_size_limit docker
suite (#65872)
4d0af109574 is described below
commit 4d0af10957430e88e497b77962b636e40cb782ab
Author: Dongyang Li <[email protected]>
AuthorDate: Wed Jul 22 17:06:39 2026 +0800
[branch-4.1][fix](case) Fix profile_size_limit docker suite (#65872)
### What problem does this PR solve?
Backport the `profile_size_limit` case fix from #60087 to branch-4.1.
In branch-4.1 Docker Case build 203696, the case is rejected before
cluster startup because the suite group is declared as the single value
`docker, nonConcurrent` rather than `docker`. The original case also
reads the outer regression FE address after entering a Docker cluster.
### What is changed?
- Declare the case in the `docker` group.
- Resolve the master FE host and HTTP port from the Docker cluster.
- Pass the Docker FE base URL through profile API helpers.
Jira: DORIS-27234
TeamCity:
http://172.20.48.17:8111/buildConfiguration/Doris_Doris_x64_branch41_Regression_Docker_Case/203696
Upstream fix: #60087
---
.../suites/query_profile/profile_size_limit.groovy | 45 +++++++++++-----------
1 file changed, 22 insertions(+), 23 deletions(-)
diff --git a/regression-test/suites/query_profile/profile_size_limit.groovy
b/regression-test/suites/query_profile/profile_size_limit.groovy
index f743c278616..4ccf71888dc 100644
--- a/regression-test/suites/query_profile/profile_size_limit.groovy
+++ b/regression-test/suites/query_profile/profile_size_limit.groovy
@@ -27,30 +27,28 @@ import groovy.json.StringEscapeUtils
final String PROFILE_SIZE_NOT_GREATER_THAN_ZERO_MSG = "Profile size is not
greater than 0"
final String PROFILE_SIZE_GREATER_THAN_LIMIT_MSG = "Profile size is greater
than limit"
-def getProfileList = {
- def dst = 'http://' + context.config.feHttpAddress
- def conn = new URL(dst + "/rest/v1/query_profile").openConnection()
+def getProfileList = { String feBaseUrl ->
+ def conn = new URL(feBaseUrl + "/rest/v1/query_profile").openConnection()
conn.setRequestMethod("GET")
- def encoding =
Base64.getEncoder().encodeToString((context.config.feHttpUser + ":" +
- (context.config.feHttpPassword == null ? "" :
context.config.feHttpPassword)).getBytes("UTF-8"))
+ def encoding = Base64.getEncoder().encodeToString(("root" + ":" +
+ "").getBytes("UTF-8"))
conn.setRequestProperty("Authorization", "Basic ${encoding}")
return conn.getInputStream().getText()
}
-def getProfile = { id ->
- def dst = 'http://' + context.config.feHttpAddress
- def conn = new URL(dst +
"/api/profile/text/?query_id=$id").openConnection()
- conn.setRequestMethod("GET")
- def encoding =
Base64.getEncoder().encodeToString((context.config.feHttpUser + ":" +
- (context.config.feHttpPassword == null ? "" :
context.config.feHttpPassword)).getBytes("UTF-8"))
- conn.setRequestProperty("Authorization", "Basic ${encoding}")
- return conn.getInputStream().getText()
+def getProfile = { String feBaseUrl, String id ->
+ def conn = new URL(feBaseUrl +
"/api/profile/text/?query_id=$id").openConnection()
+ conn.setRequestMethod("GET")
+ def encoding = Base64.getEncoder().encodeToString(("root" + ":" +
+ "").getBytes("UTF-8"))
+ conn.setRequestProperty("Authorization", "Basic ${encoding}")
+ return conn.getInputStream().getText()
}
-def getProfileWithToken = { token ->
- def wholeString = getProfileList()
+def getProfileWithToken = { String feBaseUrl, String token ->
+ def wholeString = getProfileList(feBaseUrl)
List profileData = new JsonSlurper().parseText(wholeString).data.rows
- String profileId = "";
+ String profileId = "";
logger.info("{}", token)
for (def profileItem in profileData) {
@@ -64,11 +62,11 @@ def getProfileWithToken = { token ->
// Sleep 2 seconds to make sure profile collection is done
Thread.sleep(2000)
- def String profile = getProfile(profileId).toString()
+ def String profile = getProfile(feBaseUrl, profileId).toString()
return profile;
}
-suite('profile_size_limit', 'docker, nonConcurrent') {
+suite('profile_size_limit', 'docker') {
def options = new ClusterOptions()
options.beNum = 1
options.enableDebugPoints()
@@ -132,14 +130,15 @@ suite('profile_size_limit', 'docker, nonConcurrent') {
(9010, "CTO_Technical_Strategy_Lead", 42);
"""
- def feHttpAddress = context.config.feHttpAddress.split(":")
- def feHost = feHttpAddress[0]
- def fePort = feHttpAddress[1] as int
+ def fe = cluster.getMasterFe()
+ def feHost = fe.host
+ def fePort = fe.httpPort
+ def feBaseUrl = 'http://' + feHost + ':' + fePort
sql """
select "${token}", * from profile_size_limit;
"""
- def String profile = getProfileWithToken(token)
+ def String profile = getProfileWithToken(feBaseUrl, token)
logger.info("Profile of ${token} size: ${profile.size()}")
assertTrue(profile.size() > 0, PROFILE_SIZE_NOT_GREATER_THAN_ZERO_MSG)
@@ -154,7 +153,7 @@ suite('profile_size_limit', 'docker, nonConcurrent') {
sql """
select "${token}", * from profile_size_limit;
"""
- profile = getProfileWithToken(token)
+ profile = getProfileWithToken(feBaseUrl, token)
logger.info("Profile of ${token} size: ${profile.size()}, limit:
${maxProfileSize}")
assertTrue(profile.size() <= maxProfileSize,
PROFILE_SIZE_GREATER_THAN_LIMIT_MSG)
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]