Skip to content

Commit

Permalink
Revert "insertByTablet execute synchronize"
Browse files Browse the repository at this point in the history
This reverts commit 24817a3.
  • Loading branch information
liyuheng55555 committed Sep 21, 2023
1 parent de052f3 commit 4a98b5d
Showing 1 changed file with 14 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,20 @@ public IoTDBSessionBase(DBConfig dbConfig) {

public Status insertOneBatchByTablet(IBatch batch) {
Tablet tablet = genTablet(batch);
try {
if (config.isVECTOR()) {
sessionWrapper.insertAlignedTablet(tablet);
} else {
sessionWrapper.insertTablet(tablet);
}
return new Status(true);
} catch (IoTDBConnectionException | StatementExecutionException e) {
return new Status(false, 0, e, e.toString());
}
future =
service.submit(
() -> {
try {
if (config.isVECTOR()) {
sessionWrapper.insertAlignedTablet(tablet);
} else {
sessionWrapper.insertTablet(tablet);
}
} catch (IoTDBConnectionException | StatementExecutionException e) {
LOGGER.error("insert tablet failed", e);
}
});
return waitFuture();
}

public Status insertOneBatchByRecord(IBatch batch) {
Expand Down

0 comments on commit 4a98b5d

Please sign in to comment.