public static int getJdkVersion() {
    String[] javaVersionElements = System.getProperty("java.version").split("-")[0].split("\\.");
    if (Integer.parseInt(javaVersionElements[0]) == 1) {
      return Integer.parseInt(javaVersionElements[1]);
    } else {
      return Integer.parseInt(javaVersionElements[0]);
    }
  }
get JDK version.

@return JDK version (int type)
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/utils/JVMCommonUtils.java