englefly commented on code in PR #14370: URL: https://github.com/apache/doris/pull/14370#discussion_r1027311388
########## fe/fe-core/src/main/java/org/apache/doris/catalog/InternalSchemaInitializer.java: ########## @@ -46,20 +44,26 @@ import java.util.List; import java.util.Map; -public class StatisticStorageInitializer extends Thread { +public class InternalSchemaInitializer extends Thread { - private static final Logger LOG = LogManager.getLogger(StatisticStorageInitializer.class); + private static final Logger LOG = LogManager.getLogger(InternalSchemaInitializer.class); public static boolean forTest = false; + /** + * If internal table creation failed, will retry after below seconds. + */ + public static final int TABLE_CREATION_RETRY_INTERVAL_IN_SECONDS = 5; + + public void run() { - if (forTest) { + if (forTest || (!Env.getCurrentEnv().isMaster() && Env.getCurrentEnv().isReady())) { Review Comment: `forTest` means for ut or regression? ########## fe/fe-core/src/main/java/org/apache/doris/statistics/ColumnStatistic.java: ########## @@ -110,6 +110,8 @@ public static ColumnStatistic fromResultRow(ResultRow resultRow) { columnStatisticBuilder.setNumNulls(Double.parseDouble(resultRow.getColumnValue("null_count"))); columnStatisticBuilder.setDataSize(Double .parseDouble(resultRow.getColumnValue("data_size_in_bytes"))); + columnStatisticBuilder.setAvgSizeByte(columnStatisticBuilder.getDataSize() Review Comment: if there are some rows to be deleted or rows need to be merged, the AvgSizeByte may becomes larger, is that right? ########## fe/fe-core/src/main/java/org/apache/doris/catalog/InternalSchemaInitializer.java: ########## @@ -46,20 +44,26 @@ import java.util.List; import java.util.Map; -public class StatisticStorageInitializer extends Thread { +public class InternalSchemaInitializer extends Thread { - private static final Logger LOG = LogManager.getLogger(StatisticStorageInitializer.class); + private static final Logger LOG = LogManager.getLogger(InternalSchemaInitializer.class); public static boolean forTest = false; + /** + * If internal table creation failed, will retry after below seconds. + */ + public static final int TABLE_CREATION_RETRY_INTERVAL_IN_SECONDS = 5; + + public void run() { - if (forTest) { + if (forTest || (!Env.getCurrentEnv().isMaster() && Env.getCurrentEnv().isReady())) { Review Comment: how about if it is master, but its env is not ready? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org