You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by qi...@apache.org on 2020/07/14 04:08:17 UTC

[incubator-iotdb] branch master updated (7e628d2 -> fcad569)

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

qiaojialin pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git.


    from 7e628d2  [IOTDB-716] add lZ4 compress method (#1448)
     new 466a0ba  fix check properties
     new fcad569  fix check properties

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java    | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)


[incubator-iotdb] 01/02: fix check properties

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit 466a0baa74a007d8bd78456f81a3bc6b71ac5b33
Author: HTHou <hh...@outlook.com>
AuthorDate: Mon Jul 13 21:18:27 2020 +0800

    fix check properties
---
 server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java b/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
index 2f7e2c8..ccbe74f 100644
--- a/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
+++ b/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
@@ -181,8 +181,10 @@ public class IoTDBConfigCheck {
     }
 
     // no tmp file, read properties from system.properties
-    try (FileInputStream inputStream = new FileInputStream(propertiesFile)) {
-      properties.load(new InputStreamReader(inputStream, TSFileConfig.STRING_CHARSET));
+    try (FileInputStream inputStream = new FileInputStream(propertiesFile);
+        InputStreamReader inputStreamReader = new InputStreamReader(
+            inputStream, TSFileConfig.STRING_CHARSET)) {
+      properties.load(inputStreamReader);
     }
     // need to upgrade from 0.9 to 0.10
     if (!properties.containsKey(IOTDB_VERSION_STRING)) {


[incubator-iotdb] 02/02: fix check properties

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit fcad5690e5701423cc9be79f773f2d18449a8249
Author: HTHou <hh...@outlook.com>
AuthorDate: Mon Jul 13 21:57:24 2020 +0800

    fix check properties
---
 .../src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java  | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java b/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
index ccbe74f..e97a52d 100644
--- a/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
+++ b/server/src/main/java/org/apache/iotdb/db/conf/IoTDBConfigCheck.java
@@ -221,9 +221,9 @@ public class IoTDBConfigCheck {
       if (propertiesFile.exists()) {
         Files.delete(propertiesFile.toPath());
       }
-      // rename system.properties.tmp to system.properties
-      FileUtils.moveFile(tmpPropertiesFile, propertiesFile);
     }
+    // rename system.properties.tmp to system.properties
+    FileUtils.moveFile(tmpPropertiesFile, propertiesFile);
   }
 
 
@@ -252,9 +252,9 @@ public class IoTDBConfigCheck {
       if (propertiesFile.exists()) {
         Files.delete(propertiesFile.toPath());
       }
-      // rename system.properties.tmp to system.properties
-      FileUtils.moveFile(tmpPropertiesFile, propertiesFile);
     }
+    // rename system.properties.tmp to system.properties
+    FileUtils.moveFile(tmpPropertiesFile, propertiesFile);
   }
 
   /**