Skip to content

Commit 250e34b

Browse files
【Rpc】: RPC Column Compression (V0.1) (#15438)
* Added RPC columnEncoder(Rle,Plain) and MetaHead.java * Improve RpcEncoder logic. * decoder * RPC compressed: The column encoding and decoding of the Plain method is performed correctly. * Implement the initial full-data compression logic for RPC. * Refine RPC compression logic * Fix the BufferUnderflowException in ByteBuffer usage. * add Corilla columnar encoding/decoding logic * add chimp columnar encoding/decoding logic * add Zigzag columnar encoding/decoding logic * add Sprintz columnar encoding/decoding logic * add RLBE columnar encoding/decoding logic * add Dictionary columnar encoding/decoding logic * add TS_2DIFF columnar encoding/decoding logic * add RPC columnar decompression and decoding for monitoring data * Refactor the encoding and compression structure. * Add RPC test cases * Fix code structure * Fix the metric collection issue for RPC compression. * remove gen-java code. * refactor compression * add test * Remove generated code * Remove unused class * Fix compatibility of PlainEncoder for binary * fix int32 incompatitbility * fix date incompatibility * fix null date * spotless * revert changes regarding compact protocol * refactor configurations * fix compression * fix test * fix test * Set enableCompression to true by default. Add tablet compression min size. * fix ut --------- Co-authored-by: Tian Jiang <jt2594838@163.com>
1 parent 19810e5 commit 250e34b

28 files changed

Lines changed: 1345 additions & 83 deletions

File tree

integration-test/src/main/java/org/apache/iotdb/it/env/cluster/EnvUtils.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,8 @@ private static Pair<Integer, Integer> getClusterNodesNum(final int index) {
195195
Integer.parseInt(System.getProperty(LIGHT_WEIGHT_STANDALONE_MODE_DATA_NODE_NUM)));
196196
case SCALABLE_SINGLE_NODE_MODE:
197197
return new Pair<>(
198-
Integer.parseInt(System.getProperty(SCALABLE_SINGLE_NODE_MODE_CONFIG_NODE_NUM)),
199-
Integer.parseInt(System.getProperty(SCALABLE_SINGLE_NODE_MODE_DATA_NODE_NUM)));
198+
Integer.parseInt(System.getProperty(SCALABLE_SINGLE_NODE_MODE_CONFIG_NODE_NUM, "1")),
199+
Integer.parseInt(System.getProperty(SCALABLE_SINGLE_NODE_MODE_DATA_NODE_NUM, "1")));
200200
case HIGH_PERFORMANCE_MODE:
201201
return new Pair<>(
202202
Integer.parseInt(System.getProperty(HIGH_PERFORMANCE_MODE_CONFIG_NODE_NUM)),

integration-test/src/main/java/org/apache/iotdb/it/env/remote/env/RemoteServerEnv.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ public ISessionPool getSessionPool(int maxSize) {
225225
.maxSize(maxSize)
226226
.fetchSize(SessionConfig.DEFAULT_FETCH_SIZE)
227227
.waitToGetSessionTimeoutInMs(60_000)
228-
.enableCompression(false)
228+
.enableIoTDBRpcCompression(false)
229229
.zoneId(null)
230230
.enableRedirection(SessionConfig.DEFAULT_REDIRECTION_MODE)
231231
.connectionTimeoutInMs(SessionConfig.DEFAULT_CONNECTION_TIMEOUT_MS)
@@ -246,7 +246,7 @@ public ITableSessionPool getTableSessionPool(int maxSize) {
246246
.maxSize(maxSize)
247247
.fetchSize(SessionConfig.DEFAULT_FETCH_SIZE)
248248
.waitToGetSessionTimeoutInMs(60_000)
249-
.enableCompression(false)
249+
.enableThriftCompression(false)
250250
.zoneId(null)
251251
.enableRedirection(SessionConfig.DEFAULT_REDIRECTION_MODE)
252252
.connectionTimeoutInMs(SessionConfig.DEFAULT_CONNECTION_TIMEOUT_MS)
@@ -267,7 +267,7 @@ public ITableSessionPool getTableSessionPool(int maxSize, String database) {
267267
.maxSize(maxSize)
268268
.fetchSize(SessionConfig.DEFAULT_FETCH_SIZE)
269269
.waitToGetSessionTimeoutInMs(60_000)
270-
.enableCompression(false)
270+
.enableThriftCompression(false)
271271
.zoneId(null)
272272
.enableRedirection(SessionConfig.DEFAULT_REDIRECTION_MODE)
273273
.connectionTimeoutInMs(SessionConfig.DEFAULT_CONNECTION_TIMEOUT_MS)

integration-test/src/test/java/org/apache/iotdb/session/it/IoTDBSessionCompressedIT.java

Lines changed: 363 additions & 0 deletions
Large diffs are not rendered by default.

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/data/ImportDataTable.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public void init() throws InterruptedException {
7272
.user(username)
7373
.password(password)
7474
.maxSize(threadNum + 1)
75-
.enableCompression(false)
75+
.enableThriftCompression(false)
7676
.enableRedirection(false)
7777
.enableAutoFetch(false)
7878
.database(database)

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/data/ImportDataTree.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ public void init()
6868
.user(username)
6969
.password(password)
7070
.maxSize(threadNum + 1)
71-
.enableCompression(false)
71+
.enableIoTDBRpcCompression(false)
7272
.enableRedirection(false)
7373
.enableAutoFetch(false)
7474
.build();

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/schema/ExportSchemaTable.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public void init() throws InterruptedException {
5858
.user(username)
5959
.password(password)
6060
.maxSize(threadNum + 1)
61-
.enableCompression(false)
61+
.enableThriftCompression(false)
6262
.enableRedirection(false)
6363
.enableAutoFetch(false)
6464
.database(database)

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/schema/ImportSchemaTable.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public void init() throws InterruptedException {
5454
.user(username)
5555
.password(password)
5656
.maxSize(threadNum + 1)
57-
.enableCompression(false)
57+
.enableThriftCompression(false)
5858
.enableRedirection(false)
5959
.enableAutoFetch(false)
6060
.database(database)

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/schema/ImportSchemaTree.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public void init()
6767
.user(username)
6868
.password(password)
6969
.maxSize(threadNum + 1)
70-
.enableCompression(false)
70+
.enableIoTDBRpcCompression(false)
7171
.enableRedirection(false)
7272
.enableAutoFetch(false)
7373
.build();

iotdb-client/cli/src/main/java/org/apache/iotdb/tool/tsfile/ImportTsFile.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ public static int importFromTargetPath() {
358358
.user(username)
359359
.password(password)
360360
.maxSize(threadNum + 1)
361-
.enableCompression(false)
361+
.enableIoTDBRpcCompression(false)
362362
.enableRedirection(false)
363363
.enableAutoFetch(false)
364364
.build();

0 commit comments

Comments
 (0)