This is an automated email from the ASF dual-hosted git repository.

yiguolei pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-2.1 by this push:
     new 1ee58b216b4 [fix](test) fix fe UT failed because of timeout (#51699)
1ee58b216b4 is described below

commit 1ee58b216b41be01b4a4b9fe470a0a6285b335c0
Author: 924060929 <[email protected]>
AuthorDate: Mon Jun 16 09:50:51 2025 +0800

    [fix](test) fix fe UT failed because of timeout (#51699)
    
    fix fe UT failed because of timeout
---
 .../src/test/java/org/apache/doris/qe/HmsQueryCacheTest.java     | 9 +++++++++
 .../src/test/java/org/apache/doris/utframe/MockedFrontend.java   | 4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git 
a/fe/fe-core/src/test/java/org/apache/doris/qe/HmsQueryCacheTest.java 
b/fe/fe-core/src/test/java/org/apache/doris/qe/HmsQueryCacheTest.java
index 11df79402bf..4d686205765 100644
--- a/fe/fe-core/src/test/java/org/apache/doris/qe/HmsQueryCacheTest.java
+++ b/fe/fe-core/src/test/java/org/apache/doris/qe/HmsQueryCacheTest.java
@@ -77,12 +77,16 @@ public class HmsQueryCacheTest extends AnalyzeCheckTestBase 
{
     @Mocked
     private HiveScanNode hiveScanNode4;
 
+    private int originCacheLastVersionIntervalSecond;
+
     @Override
     protected void runBeforeAll() throws Exception {
         FeConstants.runningUnitTest = true;
         Config.enable_query_hive_views = true;
         Config.cache_enable_sql_mode = true;
         Config.cache_enable_partition_mode = true;
+        this.originCacheLastVersionIntervalSecond = 
Config.cache_last_version_interval_second;
+        Config.cache_last_version_interval_second = 300; // 5 minutes
         connectContext.getSessionVariable().setEnableSqlCache(true);
 
         env = Env.getCurrentEnv();
@@ -107,6 +111,11 @@ public class HmsQueryCacheTest extends 
AnalyzeCheckTestBase {
         mgr.getInternalCatalog().createTable(createTableStmt);
     }
 
+    @Override
+    protected void runAfterAll() throws Exception {
+        Config.cache_last_version_interval_second = 
originCacheLastVersionIntervalSecond;
+    }
+
     private void init(HMSExternalCatalog hmsCatalog) {
         Deencapsulation.setField(hmsCatalog, "initialized", true);
         Deencapsulation.setField(hmsCatalog, "objectCreated", true);
diff --git 
a/fe/fe-core/src/test/java/org/apache/doris/utframe/MockedFrontend.java 
b/fe/fe-core/src/test/java/org/apache/doris/utframe/MockedFrontend.java
index 6382621d905..88f26f4590f 100644
--- a/fe/fe-core/src/test/java/org/apache/doris/utframe/MockedFrontend.java
+++ b/fe/fe-core/src/test/java/org/apache/doris/utframe/MockedFrontend.java
@@ -192,8 +192,8 @@ public class MockedFrontend {
         }
         Thread feThread = new Thread(new FERunnable(this, args), FE_PROCESS);
         feThread.start();
-        // wait the catalog to be ready until timeout (30 seconds)
-        waitForCatalogReady(30 * 1000);
+        // wait the catalog to be ready until timeout (5 minutes)
+        waitForCatalogReady(300 * 1000);
     }
 
     private void waitForCatalogReady(long timeoutMs) throws FeStartException {


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

Reply via email to