public void put(Object... keyOrValue) throws IOException {
    if (keyOrValue.length % 2 != 0) {
      throw new IllegalArgumentException(
          "Length of parameters should be evenly divided by 2, but the actual length is "
              + keyOrValue.length
              + " : "
              + Arrays.toString(keyOrValue));
    }
    try (AutoCloseableLock ignore = AutoCloseableLock.acquire(lock.writeLock())) {
      // read old properties
      Properties properties = readWithoutLock(formalFile);
      // store new properties
      for (int i = 0; i < keyOrValue.length; i += 2) {
        properties.put(keyOrValue[i], keyOrValue[i + 1]);
      }
      writeWithoutLock(properties, tmpFile);
      // replace file
      replaceFormalFile();
    }
  }
Put key and value into properties

@param keyOrValue [key0, value0, key1, value1, ... ]
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/file/SystemPropertiesHandler.java