diff --git a/fe/fe-common/src/main/java/org/apache/doris/common/Config.java b/fe/fe-common/src/main/java/org/apache/doris/common/Config.java index 689c85940dfc39..be0390db584ca9 100644 --- a/fe/fe-common/src/main/java/org/apache/doris/common/Config.java +++ b/fe/fe-common/src/main/java/org/apache/doris/common/Config.java @@ -2180,7 +2180,7 @@ public class Config extends ConfigBase { * only for certain test type. E.g. only settting batch_size to small * value for p0. */ - @ConfField(mutable = true, masterOnly = false, options = {"p0"}) + @ConfField(mutable = true, masterOnly = false, options = {"p0", "daily", "rqg"}) public static String fuzzy_test_type = ""; /** @@ -2189,6 +2189,12 @@ public class Config extends ConfigBase { @ConfField(mutable = true, masterOnly = false) public static boolean use_fuzzy_session_variable = false; + /** + * Set config variables randomly to check more issues in github workflow + */ + @ConfField(mutable = true, masterOnly = false) + public static boolean use_fuzzy_conf = false; + /** * Max num of same name meta informatntion in catalog recycle bin. * Default is 3. diff --git a/fe/fe-core/src/main/java/org/apache/doris/DorisFE.java b/fe/fe-core/src/main/java/org/apache/doris/DorisFE.java index d5b7cd7354eb1f..d3539e96f8162b 100755 --- a/fe/fe-core/src/main/java/org/apache/doris/DorisFE.java +++ b/fe/fe-core/src/main/java/org/apache/doris/DorisFE.java @@ -61,6 +61,7 @@ import java.nio.channels.FileLock; import java.nio.channels.OverlappingFileLockException; import java.nio.file.StandardOpenOption; +import java.time.LocalDate; import java.util.concurrent.TimeUnit; public class DorisFE { @@ -162,6 +163,8 @@ public static void start(String dorisHomeDir, String pidDir, String[] args, Star System.exit(-1); } + fuzzyConfigs(); + LOG.info("Doris FE starting..."); FrontendOptions.init(); @@ -529,6 +532,16 @@ public static void overwriteConfigs() { } } + private static void fuzzyConfigs() { + if (!Config.use_fuzzy_conf) { + return; + } + if (Config.fuzzy_test_type.equalsIgnoreCase("daily") || Config.fuzzy_test_type.equalsIgnoreCase("rqg")) { + Config.random_add_cluster_keys_for_mow = (LocalDate.now().getDayOfMonth() % 2 == 0); + LOG.info("fuzzy set random_add_cluster_keys_for_mow={}", Config.random_add_cluster_keys_for_mow); + } + } + public static class StartupOptions { public boolean enableHttpServer = true; public boolean enableQeService = true;