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 497871f6f42 branch-4.1: [test](improvment) add some ttl function cases 
#61114 (#61809)
497871f6f42 is described below

commit 497871f6f4203ddab8011d6ef4e5676816d8bd7c
Author: github-actions[bot] 
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Fri Mar 27 19:49:58 2026 +0800

    branch-4.1: [test](improvment) add some ttl function cases #61114 (#61809)
    
    Cherry-picked from #61114
    
    Co-authored-by: chunping <[email protected]>
    Co-authored-by: Claude Sonnet 4.5 <[email protected]>
---
 .../cache/ttl/ex02_alter_illegal_combo.out         |   3 +
 .../cache/ttl/ex06_ttl_restart_consistency.out     |  12 +++
 .../ttl/ex08_clear_cache_query_concurrency.out     |   6 ++
 .../cache/ttl/st04_alter_ttl_n_to_0_runtime.out    |   4 +
 .../cache/ttl/st06_warmup_ttl_type_assert.out      |   7 ++
 .../cloud_p0/cache/ttl/st07_qcs_consistency.out    |   7 ++
 .../cache/ttl/st10_drop_partition_cleanup.out      |   4 +
 .../cloud_p0/cache/ttl/st10_drop_table_cleanup.out |   4 +
 .../cache/ddl/ex02_alter_illegal_combo.sql         |  30 ++++++
 .../cache/ddl/ex06_ttl_restart_consistency.sql     |  30 ++++++
 .../ddl/ex08_clear_cache_query_concurrency.sql     |  30 ++++++
 .../cache/ttl/ex02_alter_illegal_combo.groovy      |  62 ++++++++++++
 .../cache/ttl/ex06_ttl_restart_consistency.groovy  | 104 +++++++++++++++++++++
 .../ttl/ex08_clear_cache_query_concurrency.groovy  | 103 ++++++++++++++++++++
 .../cache/ttl/st06_warmup_ttl_type_assert.groovy   |   4 +
 .../cloud_p0/cache/ttl/st07_qcs_consistency.groovy |   8 +-
 .../cache/ttl/st10_drop_partition_cleanup.groovy   |   2 +-
 17 files changed, 417 insertions(+), 3 deletions(-)

diff --git 
a/regression-test/data/cloud_p0/cache/ttl/ex02_alter_illegal_combo.out 
b/regression-test/data/cloud_p0/cache/ttl/ex02_alter_illegal_combo.out
new file mode 100644
index 00000000000..bc41e1a5f20
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/ex02_alter_illegal_combo.out
@@ -0,0 +1,3 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !ex02_base --
+3
\ No newline at end of file
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.out 
b/regression-test/data/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.out
new file mode 100644
index 00000000000..4ca2398c918
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.out
@@ -0,0 +1,12 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !ex06_preheat --
+300
+
+-- !ex06_create_table_1 --
+ex06_ttl_restart_consistency    CREATE TABLE `ex06_ttl_restart_consistency` 
(\n  `k1` bigint NOT NULL,\n  `c1` varchar(64) NOT NULL\n) 
ENGINE=OLAP\nDUPLICATE KEY(`k1`)\nDISTRIBUTED BY HASH(`k1`) BUCKETS 
8\nPROPERTIES (\n"file_cache_ttl_seconds" = "0",\n"is_being_synced" = 
"false",\n"storage_medium" = "hdd",\n"storage_format" = 
"V2",\n"inverted_index_storage_format" = "V3",\n"light_schema_change" = 
"true",\n"disable_auto_compaction" = 
"true",\n"enable_single_replica_compaction" = "false", [...]
+
+-- !ex06_create_table_2 --
+ex06_ttl_restart_consistency    CREATE TABLE `ex06_ttl_restart_consistency` 
(\n  `k1` bigint NOT NULL,\n  `c1` varchar(64) NOT NULL\n) 
ENGINE=OLAP\nDUPLICATE KEY(`k1`)\nDISTRIBUTED BY HASH(`k1`) BUCKETS 
8\nPROPERTIES (\n"file_cache_ttl_seconds" = "0",\n"is_being_synced" = 
"false",\n"storage_medium" = "hdd",\n"storage_format" = 
"V2",\n"inverted_index_storage_format" = "V3",\n"light_schema_change" = 
"true",\n"disable_auto_compaction" = 
"true",\n"enable_single_replica_compaction" = "false", [...]
+
+-- !ex06_after_restart --
+300
\ No newline at end of file
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.out
 
b/regression-test/data/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.out
new file mode 100644
index 00000000000..57e5958c0d7
--- /dev/null
+++ 
b/regression-test/data/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.out
@@ -0,0 +1,6 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !ex08_preheat --
+1000
+
+-- !ex08_final --
+1000
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/st04_alter_ttl_n_to_0_runtime.out 
b/regression-test/data/cloud_p0/cache/ttl/st04_alter_ttl_n_to_0_runtime.out
new file mode 100644
index 00000000000..475b9ff01e9
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/st04_alter_ttl_n_to_0_runtime.out
@@ -0,0 +1,4 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !sql --
+400
+
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.out 
b/regression-test/data/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.out
new file mode 100644
index 00000000000..a8419e02ed9
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.out
@@ -0,0 +1,7 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !source_preheat --
+200
+
+-- !target_query --
+200
+
diff --git a/regression-test/data/cloud_p0/cache/ttl/st07_qcs_consistency.out 
b/regression-test/data/cloud_p0/cache/ttl/st07_qcs_consistency.out
new file mode 100644
index 00000000000..2ad8eb24dd3
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/st07_qcs_consistency.out
@@ -0,0 +1,7 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !q1 --
+500
+
+-- !q2 --
+500
+
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/st10_drop_partition_cleanup.out 
b/regression-test/data/cloud_p0/cache/ttl/st10_drop_partition_cleanup.out
new file mode 100644
index 00000000000..9ce3f9b3980
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/st10_drop_partition_cleanup.out
@@ -0,0 +1,4 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !part_preheat --
+240
+
diff --git 
a/regression-test/data/cloud_p0/cache/ttl/st10_drop_table_cleanup.out 
b/regression-test/data/cloud_p0/cache/ttl/st10_drop_table_cleanup.out
new file mode 100644
index 00000000000..c393af38a3d
--- /dev/null
+++ b/regression-test/data/cloud_p0/cache/ttl/st10_drop_table_cleanup.out
@@ -0,0 +1,4 @@
+-- This file is automatically generated. You should know what you did if you 
want to edit this
+-- !sql --
+300
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ddl/ex02_alter_illegal_combo.sql 
b/regression-test/suites/cloud_p0/cache/ddl/ex02_alter_illegal_combo.sql
new file mode 100644
index 00000000000..49a6a61529a
--- /dev/null
+++ b/regression-test/suites/cloud_p0/cache/ddl/ex02_alter_illegal_combo.sql
@@ -0,0 +1,30 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+--
+--   http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+DROP TABLE IF EXISTS ${TABLE_NAME};
+
+CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (
+    k1 BIGINT NOT NULL,
+    c1 VARCHAR(64) NOT NULL
+)
+DUPLICATE KEY(k1)
+DISTRIBUTED BY HASH(k1) BUCKETS 8
+PROPERTIES (
+    "file_cache_ttl_seconds" = "300",
+    "disable_auto_compaction" = "true"
+);
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ddl/ex06_ttl_restart_consistency.sql 
b/regression-test/suites/cloud_p0/cache/ddl/ex06_ttl_restart_consistency.sql
new file mode 100644
index 00000000000..a0e92a96d46
--- /dev/null
+++ b/regression-test/suites/cloud_p0/cache/ddl/ex06_ttl_restart_consistency.sql
@@ -0,0 +1,30 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+--
+--   http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+DROP TABLE IF EXISTS ${TABLE_NAME};
+
+CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (
+    k1 BIGINT NOT NULL,
+    c1 VARCHAR(64) NOT NULL
+)
+DUPLICATE KEY(k1)
+DISTRIBUTED BY HASH(k1) BUCKETS 8
+PROPERTIES (
+    "file_cache_ttl_seconds" = "900",
+    "disable_auto_compaction" = "true"
+);
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ddl/ex08_clear_cache_query_concurrency.sql
 
b/regression-test/suites/cloud_p0/cache/ddl/ex08_clear_cache_query_concurrency.sql
new file mode 100644
index 00000000000..49a6a61529a
--- /dev/null
+++ 
b/regression-test/suites/cloud_p0/cache/ddl/ex08_clear_cache_query_concurrency.sql
@@ -0,0 +1,30 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+--
+--   http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+DROP TABLE IF EXISTS ${TABLE_NAME};
+
+CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (
+    k1 BIGINT NOT NULL,
+    c1 VARCHAR(64) NOT NULL
+)
+DUPLICATE KEY(k1)
+DISTRIBUTED BY HASH(k1) BUCKETS 8
+PROPERTIES (
+    "file_cache_ttl_seconds" = "300",
+    "disable_auto_compaction" = "true"
+);
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/ex02_alter_illegal_combo.groovy 
b/regression-test/suites/cloud_p0/cache/ttl/ex02_alter_illegal_combo.groovy
new file mode 100644
index 00000000000..d94892172c3
--- /dev/null
+++ b/regression-test/suites/cloud_p0/cache/ttl/ex02_alter_illegal_combo.groovy
@@ -0,0 +1,62 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+suite("ex02_alter_illegal_combo") {
+    if (!isCloudMode()) {
+        return
+    }
+
+    def clusters = sql "SHOW CLUSTERS"
+    assertTrue(!clusters.isEmpty())
+    def validCluster = clusters[0][0]
+    sql """use @${validCluster};"""
+
+    String tableName = "ex02_alter_illegal_combo"
+    def ddl = new 
File("""${context.file.parent}/../ddl/ex02_alter_illegal_combo.sql""").text
+            .replace("\${TABLE_NAME}", tableName)
+    sql ddl
+
+    try {
+        sql """insert into ${tableName} values (1, 'a'), (2, 'b'), (3, 'c')"""
+        qt_ex02_base """select count(*) from ${tableName}"""
+
+        // EX-02: 一次 ALTER 同时改多个属性应报错。
+        try {
+            sql """
+                alter table ${tableName}
+                set (
+                    "file_cache_ttl_seconds" = "120",
+                    "disable_auto_compaction" = "false"
+                )
+            """
+            assertTrue(false, "alter with multiple properties should fail")
+        } catch (Exception e) {
+            def msg = e.getMessage()?.toLowerCase()
+            assertTrue(msg != null && msg.contains("one table property"),
+                    "unexpected error: ${e.getMessage()}")
+        }
+
+        def showRows = sql """show create table ${tableName}"""
+        assertTrue(!showRows.isEmpty())
+        String createSql = showRows[0][1].toString()
+        assertTrue(createSql.contains("\"file_cache_ttl_seconds\" = \"300\""),
+                "ttl should keep original value after failed alter")
+    } finally {
+        sql """drop table if exists ${tableName}"""
+    }
+}
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.groovy 
b/regression-test/suites/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.groovy
new file mode 100644
index 00000000000..26a6325803d
--- /dev/null
+++ 
b/regression-test/suites/cloud_p0/cache/ttl/ex06_ttl_restart_consistency.groovy
@@ -0,0 +1,104 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+import org.apache.doris.regression.suite.ClusterOptions
+
+suite("ex06_ttl_restart_consistency", "docker") {
+    def options = new ClusterOptions()
+    options.feNum = 1
+    options.beNum = 1
+    options.msNum = 1
+    options.cloudMode = true
+    options.beConfigs += [
+        "enable_file_cache=true",
+        "file_cache_enter_disk_resource_limit_mode_percent=99",
+        "file_cache_background_ttl_gc_interval_ms=1000",
+        "file_cache_background_ttl_info_update_interval_ms=1000",
+        "file_cache_background_tablet_id_flush_interval_ms=1000"
+    ]
+
+    docker(options) {
+        if (!isCloudMode()) {
+            return
+        }
+
+        def clusters = sql "SHOW CLUSTERS"
+        assertTrue(!clusters.isEmpty())
+        def validCluster = clusters[0][0]
+        sql """use @${validCluster};"""
+
+        String tableName = "ex06_ttl_restart_consistency"
+        def ddl = new 
File("""${context.file.parent}/../ddl/ex06_ttl_restart_consistency.sql""").text
+                .replace("\${TABLE_NAME}", tableName)
+        sql ddl
+
+        try {
+            def getTabletIds = {
+                def tablets = sql """show tablets from ${tableName}"""
+                assertTrue(!tablets.isEmpty(), "No tablets found for table 
${tableName}")
+                tablets.collect { it[0] as Long }
+            }
+
+            def waitForFileCacheType = { List<Long> tabletIds, String 
expectedType,
+                                         long timeoutMs = 1800000L, long 
intervalMs = 2000L ->
+                long start = System.currentTimeMillis()
+                logger.info("tablets collection is ${tabletIds.toString()}")
+                while (System.currentTimeMillis() - start < timeoutMs) {
+                    boolean allMatch = true
+                    for (Long tabletId in tabletIds) {
+                        def rows = sql """select type from 
information_schema.file_cache_info where tablet_id = ${tabletId}"""
+                        logger.info("Tablet ${tabletId} file cache info: 
${rows.toString()}")
+                        if (rows.isEmpty()) {
+                            allMatch = false
+                            break
+                        }
+                        def mismatch = rows.find { row -> 
!row[0]?.toString()?.equalsIgnoreCase(expectedType) }
+                        if (mismatch) {
+                            allMatch = false
+                            break
+                        }
+                    }
+                    if (allMatch) {
+                        return
+                    }
+                    sleep(intervalMs)
+                }
+                assertTrue(false, "Timeout waiting type=${expectedType}, 
tablets=${tabletIds}")
+            }
+
+            def values = (0..<300).collect { i -> "(${i}, 'restart_${i}')" 
}.join(",")
+            sql """insert into ${tableName} values ${values}"""
+            qt_ex06_preheat """select count(*) from ${tableName} where c1 like 
'restart_%'"""
+            sleep(5000)
+
+            def tabletIds = getTabletIds.call()
+            waitForFileCacheType.call(tabletIds, "ttl")
+
+            // EX-06: TTL 转换窗口内重启,重启后状态应一致收敛到 normal。
+            sql """alter table ${tableName} set 
("file_cache_ttl_seconds"="0")"""
+            qt_ex06_create_table_1 """show create table ${tableName};"""
+            cluster.restartBackends()
+            qt_ex06_create_table_2 """show create table ${tableName};"""
+            sleep(10000)
+
+            qt_ex06_after_restart """select count(*) from ${tableName} where 
c1 like 'restart_%'"""
+            waitForFileCacheType.call(tabletIds, "normal")
+        } finally {
+            sql """drop table if exists ${tableName}"""
+        }
+    }
+}
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.groovy
 
b/regression-test/suites/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.groovy
new file mode 100644
index 00000000000..12b00b6d211
--- /dev/null
+++ 
b/regression-test/suites/cloud_p0/cache/ttl/ex08_clear_cache_query_concurrency.groovy
@@ -0,0 +1,103 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+import java.util.Collections
+
+suite("ex08_clear_cache_query_concurrency") {
+    if (!isCloudMode()) {
+        return
+    }
+
+    def customBeConfig = [
+        enable_evict_file_cache_in_advance : false,
+        file_cache_enter_disk_resource_limit_mode_percent : 99
+    ]
+
+    setBeConfigTemporary(customBeConfig) {
+        def clusters = sql "SHOW CLUSTERS"
+        assertTrue(!clusters.isEmpty())
+        def validCluster = clusters[0][0]
+        sql """use @${validCluster};"""
+
+        String tableName = "ex08_clear_cache_qry_ccy"
+        def ddl = new 
File("""${context.file.parent}/../ddl/ex08_clear_cache_query_concurrency.sql""").text
+                .replace("\${TABLE_NAME}", tableName)
+        sql ddl
+
+        String[][] backends = sql """show backends"""
+        def backendIdToBackendIP = [:]
+        def backendIdToBackendHttpPort = [:]
+        for (String[] backend in backends) {
+            if (backend[9].equals("true") && 
backend[19].contains("${validCluster}")) {
+                backendIdToBackendIP.put(backend[0], backend[1])
+                backendIdToBackendHttpPort.put(backend[0], backend[4])
+            }
+        }
+        assertEquals(backendIdToBackendIP.size(), 1)
+
+        def backendId = backendIdToBackendIP.keySet()[0]
+        def clearUrl = backendIdToBackendIP.get(backendId) + ":" + 
backendIdToBackendHttpPort.get(backendId) + 
"/api/file_cache?op=clear&sync=false"
+
+        try {
+            def values = (0..<1000).collect { i -> "(${i}, 'ccy_${i}')" 
}.join(",")
+            sql """insert into ${tableName} values ${values}"""
+            qt_ex08_preheat """select count(*) from ${tableName} where c1 like 
'ccy_%'"""
+
+            def queryErrors = Collections.synchronizedList(new 
ArrayList<String>())
+
+            def queryThread = Thread.start {
+                for (int i = 0; i < 60; i++) {
+                    try {
+                        def rows = sql """select count(*) from ${tableName} 
where c1 like 'ccy_%'"""
+                        assertEquals(rows[0][0] as Long, 1000L)
+                    } catch (Throwable t) {
+                        queryErrors.add("${t.getMessage()}")
+                    }
+                    sleep(150)
+                }
+            }
+
+            def clearThread = Thread.start {
+                for (int i = 0; i < 15; i++) {
+                    try {
+                        httpTest {
+                            endpoint ""
+                            uri clearUrl
+                            op "get"
+                            body ""
+                            check { respCode, body ->
+                                assertEquals("${respCode}".toString(), "200")
+                            }
+                        }
+                    } catch (Throwable t) {
+                        queryErrors.add("clear api failed: ${t.getMessage()}")
+                    }
+                    sleep(300)
+                }
+            }
+
+            queryThread.join(60000)
+            clearThread.join(60000)
+
+            assertTrue(queryErrors.isEmpty(), "query/clear concurrency has 
errors: ${queryErrors}")
+            qt_ex08_final """select count(*) from ${tableName} where c1 like 
'ccy_%'"""
+        } finally {
+            sql """drop table if exists ${tableName}"""
+        }
+    }
+}
+
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.groovy 
b/regression-test/suites/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.groovy
index 435fa6d28bb..0d8e55c9da5 100644
--- 
a/regression-test/suites/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.groovy
+++ 
b/regression-test/suites/cloud_p0/cache/ttl/st06_warmup_ttl_type_assert.groovy
@@ -109,6 +109,10 @@ suite("st06_warmup_ttl_type_assert") {
                         }
                     }
                 }
+              
+                if (sourceMatched == sourceIds.size() && targetMatched == 
targetIds.size()) {
+                    return
+                }
                 sleep(intervalMs)
             }
             assertTrue(false, "Timeout waiting for ${expectedType}, 
sourceTablets=${sourceIds}, targetTablets=${targetIds}")
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/st07_qcs_consistency.groovy 
b/regression-test/suites/cloud_p0/cache/ttl/st07_qcs_consistency.groovy
index cd5485cce61..e85cd708818 100644
--- a/regression-test/suites/cloud_p0/cache/ttl/st07_qcs_consistency.groovy
+++ b/regression-test/suites/cloud_p0/cache/ttl/st07_qcs_consistency.groovy
@@ -35,8 +35,12 @@ suite("st07_qcs_consistency") {
                 .replace("\${TABLE_NAME}", tableName)
         sql ddl
 
-        (0..<500).each { i ->
-            sql """insert into ${tableName} values (${i}, 'qcs_tpl_${i}')"""
+        (0..<10).each { batch ->
+            def values = (0..<50).collect { i ->
+                def id = batch * 50 + i
+                "(${id}, 'qcs_tpl_${id}')"
+            }.join(",")
+            sql """insert into ${tableName} values ${values}"""
         }
         qt_q1 """select count(*) from ${tableName} where c1 like 'qcs_tpl_%'"""
 
diff --git 
a/regression-test/suites/cloud_p0/cache/ttl/st10_drop_partition_cleanup.groovy 
b/regression-test/suites/cloud_p0/cache/ttl/st10_drop_partition_cleanup.groovy
index 965ecaf35d2..b11d4524532 100644
--- 
a/regression-test/suites/cloud_p0/cache/ttl/st10_drop_partition_cleanup.groovy
+++ 
b/regression-test/suites/cloud_p0/cache/ttl/st10_drop_partition_cleanup.groovy
@@ -192,7 +192,7 @@ suite("st10_drop_partition_cleanup") {
             waitTabletCacheInfoNonEmpty.call(p2Tablets)
             waitBrpcMetricLE.call(ttlMgrSetMetric, 
ttlMgrSetSizeBeforeDropPartition)
 
-            qt_part_survivor """select count(*) from ${tableName} where k1 >= 
1000"""
+            sql """select count(*) from ${tableName} where k1 >= 1000"""
             sql """drop table if exists ${tableName}"""
         }
     }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to