This is an automated email from the ASF dual-hosted git repository. rong pushed a commit to branch avoid-redirect in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit 370b2f30a846c7b93aefd7819a74c60fd22cde3c Author: Steve Yurong Su <[email protected]> AuthorDate: Wed Jul 10 15:22:13 2024 +0800 load-tsfile: Avoid request redirection caused by SessionPool param enableAutoFetch = true --- .../src/main/java/org/apache/iotdb/tool/ImportTsFile.java | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/iotdb-client/cli/src/main/java/org/apache/iotdb/tool/ImportTsFile.java b/iotdb-client/cli/src/main/java/org/apache/iotdb/tool/ImportTsFile.java index 15cdd907f8b..e417cf2d065 100644 --- a/iotdb-client/cli/src/main/java/org/apache/iotdb/tool/ImportTsFile.java +++ b/iotdb-client/cli/src/main/java/org/apache/iotdb/tool/ImportTsFile.java @@ -312,8 +312,16 @@ public class ImportTsFile extends AbstractTsFileTool { } sessionPool = - new SessionPool( - host, Integer.parseInt(port), username, password, threadNum + 1, false, false); + new SessionPool.Builder() + .host(host) + .port(Integer.parseInt(port)) + .user(username) + .password(password) + .maxSize(threadNum + 1) + .enableCompression(false) + .enableRedirection(false) + .enableAutoFetch(false) + .build(); sessionPool.setEnableQueryRedirection(false); traverseAndCollectFiles(file);
