@Override
  public void insertAlignedRecordsOfOneDevice(
      String deviceId,
      List<Long> times,
      List<List<String>> measurementsList,
      List<List<TSDataType>> typesList,
      List<List<Object>> valuesList,
      boolean haveSorted)
      throws IoTDBConnectionException, StatementExecutionException {
    int len = times.size();
    if (len != measurementsList.size() || len != valuesList.size()) {
      throw new IllegalArgumentException(
          "times, subMeasurementsList and valuesList's size should be equal");
    }
    if (enableRecordsAutoConvertTablet
        && len >= MIN_RECORDS_SIZE
        && judgeConvertOfOneDevice(measurementsList)) {
      convertToTabletAndInsert(deviceId, times, measurementsList, typesList, valuesList, true);
      return;
    }
    TSInsertRecordsOfOneDeviceReq request;
    try {
      request =
          filterAndGenTSInsertRecordsOfOneDeviceReq(
              deviceId, times, measurementsList, typesList, valuesList, haveSorted, true);
    } catch (NoValidValueException e) {
      logger.warn(ALL_VALUES_ARE_NULL_WITH_TIME, deviceId, times, measurementsList);
      return;
    }
    try {
      getSessionConnection(deviceId).insertRecordsOfOneDevice(request);
    } catch (RedirectException e) {
      handleRedirection(deviceId, e.getEndPoint());
    } catch (IoTDBConnectionException e) {
      if (enableRedirection
          && !deviceIdToEndpoint.isEmpty()
          && deviceIdToEndpoint.get(deviceId) != null) {
        logger.warn(SESSION_CANNOT_CONNECT, deviceIdToEndpoint.get(deviceId));
        deviceIdToEndpoint.remove(deviceId);

        // reconnect with default connection
        try {
          defaultSessionConnection.insertRecordsOfOneDevice(request);
        } catch (RedirectException ignored) {
        }
      } else {
        throw e;
      }
    }
  }
Insert aligned multiple rows, which can reduce the overhead of network. This method is just
like jdbc executeBatch, we pack some insert request in batch and send them to server. If you
want improve your performance, please see insertTablet method

<p>Each row could have same prefixPath but different time, number of measurements

@param haveSorted deprecated, whether the times have been sorted
@see Session#insertTablet(Tablet)
iotdb-client/session/src/main/java/org/apache/iotdb/session/Session.java