You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2021/09/25 10:35:12 UTC

[GitHub] [iotdb] HeimingZ commented on a change in pull request #3917: [IOTDB-1634][IOTDB-1571] Extend more aligned timeseries insert APIs && Fix aligned timeseries wal cannot recover

HeimingZ commented on a change in pull request #3917:
URL: https://github.com/apache/iotdb/pull/3917#discussion_r716024001



##########
File path: session/src/main/java/org/apache/iotdb/session/Session.java
##########
@@ -1425,7 +1587,11 @@ private TSInsertTabletsReq genTSInsertTabletsReq(List<Tablet> tablets, boolean s
       throws BatchExecutionException {
     TSInsertTabletsReq request = new TSInsertTabletsReq();
 
+    boolean isFirstTabletAligned = tablets.get(0).isAligned();

Review comment:
       IndexOutOfBoundsException occurs when tablets are empty

##########
File path: session/src/main/java/org/apache/iotdb/session/pool/SessionPool.java
##########
@@ -648,6 +777,37 @@ public void insertRecord(
     }
   }
 
+  /**
+   * insert aligned data in one row, if you want improve your performance, please use insertRecords
+   * method or insertTablet method.
+   *
+   * @see Session#insertRecords(List, List, List, List, List)

Review comment:
       Does insertRecords mean insertAlignedRecords?

##########
File path: session/src/main/java/org/apache/iotdb/session/Session.java
##########
@@ -861,25 +861,31 @@ public void insertRecord(
       long time,
       List<String> measurements,
       List<TSDataType> types,
-      List<Object> values,
-      boolean isAligned)
+      List<Object> values)
       throws IoTDBConnectionException, StatementExecutionException {
+    // not vector by default
     TSInsertRecordReq request =
-        genTSInsertRecordReq(deviceId, time, measurements, types, values, isAligned);
+        genTSInsertRecordReq(deviceId, time, measurements, types, values, false);
     insertRecord(deviceId, request);
   }
 
-  public void insertRecord(
-      String deviceId,
+  /**
+   * insert aligned data in one row, if you want improve your performance, please use
+   * insertAlignedRecords method or insertTablet method.
+   *
+   * @see Session#insertRecords(List, List, List, List, List)

Review comment:
       Does insertRecords mean insertAlignedRecords?

##########
File path: session/src/main/java/org/apache/iotdb/session/Session.java
##########
@@ -912,17 +918,37 @@ public void insertRecord(
       String deviceId, long time, List<String> measurements, List<String> values)
       throws IoTDBConnectionException, StatementExecutionException {
     TSInsertStringRecordReq request =
-        genTSInsertStringRecordReq(deviceId, time, measurements, values);
+        genTSInsertStringRecordReq(deviceId, time, measurements, values, false);
     insertRecord(deviceId, request);
   }
 
+  /**
+   * insert aligned data in one row, if you want improve your performance, please use
+   * insertAlignedRecords method or insertTablet method.
+   *
+   * @see Session#insertRecords(List, List, List, List, List)

Review comment:
       Does insertRecords mean insertAlignedRecords?

##########
File path: session/src/main/java/org/apache/iotdb/session/pool/SessionPool.java
##########
@@ -675,6 +835,33 @@ public void insertRecord(
     }
   }
 
+  /**
+   * insert aligned data in one row, if you want improve your performance, please use
+   * insertAlignedRecords method or insertTablet method.
+   *
+   * @see Session#insertRecords(List, List, List, List, List)

Review comment:
       Does insertRecords mean insertAlignedRecords?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org