private boolean checkSorted(List<Long> times) {
    for (int i = 1; i < times.size(); i++) {
      if (times.get(i) < times.get(i - 1)) {
        return false;
      }
    }
    return true;
  }
check whether the batch has been sorted

@return whether the batch has been sorted
iotdb-client/session/src/main/java/org/apache/iotdb/session/Session.java