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

qiaojialin pushed a commit to branch rel/1.2
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/rel/1.2 by this push:
     new be2792e62fd [IOTDB-5999] System properties patch (#10272)
be2792e62fd is described below

commit be2792e62fd214e00b993e1d155917cb2f7b1179
Author: YongzaoDan <[email protected]>
AuthorDate: Thu Jun 22 11:24:28 2023 +0800

    [IOTDB-5999] System properties patch (#10272)
---
 .../iotdb/confignode/conf/SystemPropertiesUtils.java      | 15 +++++++++++++++
 .../org/apache/iotdb/commons/conf/CommonDescriptor.java   |  5 +++++
 2 files changed, 20 insertions(+)

diff --git 
a/confignode/src/main/java/org/apache/iotdb/confignode/conf/SystemPropertiesUtils.java
 
b/confignode/src/main/java/org/apache/iotdb/confignode/conf/SystemPropertiesUtils.java
index 4406c80d7b2..54d4907297f 100644
--- 
a/confignode/src/main/java/org/apache/iotdb/confignode/conf/SystemPropertiesUtils.java
+++ 
b/confignode/src/main/java/org/apache/iotdb/confignode/conf/SystemPropertiesUtils.java
@@ -181,6 +181,21 @@ public class SystemPropertiesUtils {
       conf.setSeriesPartitionExecutorClass(seriesPartitionSlotExecutorClass);
     }
 
+    if (systemProperties.getProperty("time_partition_interval", null) == null) 
{
+      needReWrite = true;
+    } else {
+      long timePartitionInterval =
+          
Long.parseLong(systemProperties.getProperty("time_partition_interval"));
+      if (timePartitionInterval != COMMON_CONFIG.getTimePartitionInterval()) {
+        LOGGER.warn(
+            format,
+            "time_partition_interval",
+            COMMON_CONFIG.getTimePartitionInterval(),
+            timePartitionInterval);
+        COMMON_CONFIG.setTimePartitionInterval(timePartitionInterval);
+      }
+    }
+
     if (needReWrite) {
       // Re-write special parameters if necessary
       storeSystemParameters();
diff --git 
a/node-commons/src/main/java/org/apache/iotdb/commons/conf/CommonDescriptor.java
 
b/node-commons/src/main/java/org/apache/iotdb/commons/conf/CommonDescriptor.java
index 2ab38b9dbb4..7dd417d5b3b 100644
--- 
a/node-commons/src/main/java/org/apache/iotdb/commons/conf/CommonDescriptor.java
+++ 
b/node-commons/src/main/java/org/apache/iotdb/commons/conf/CommonDescriptor.java
@@ -229,6 +229,11 @@ public class CommonDescriptor {
         Integer.parseInt(
             properties.getProperty(
                 "tag_attribute_total_size", 
String.valueOf(config.getTagAttributeTotalSize()))));
+
+    config.setTimePartitionInterval(
+        Long.parseLong(
+            properties.getProperty(
+                "time_partition_interval", 
String.valueOf(config.getTimePartitionInterval()))));
   }
 
   private void loadPipeProps(Properties properties) {

Reply via email to