From 05abfbc5efc13a7ac033773d608a900201e88819 Mon Sep 17 00:00:00 2001 From: HHoflittlefish777 <77738092+HHoflittlefish777@users.noreply.github.com> Date: Fri, 28 Jul 2023 17:28:52 +0800 Subject: [PATCH] [improvement](regression-test) add compression algorithm regression test (#22303) --- .../doris/common/util/PropertyAnalyzer.java | 2 + gensrc/thrift/AgentService.thrift | 3 +- regression-test/data/compression_p0/load.csv | 5 + regression-test/data/compression_p0/load.out | 43 +++ .../snappy => compression_p1}/ipv4.csv | 0 .../suites/compress_p1/snappy/load.groovy | 45 --- .../suites/compression_p0/load.groovy | 335 ++++++++++++++++++ .../suites/compression_p1/load.groovy | 179 ++++++++++ 8 files changed, 566 insertions(+), 46 deletions(-) create mode 100644 regression-test/data/compression_p0/load.csv create mode 100644 regression-test/data/compression_p0/load.out rename regression-test/data/{compress_p1/snappy => compression_p1}/ipv4.csv (100%) delete mode 100644 regression-test/suites/compress_p1/snappy/load.groovy create mode 100644 regression-test/suites/compression_p0/load.groovy create mode 100644 regression-test/suites/compression_p1/load.groovy diff --git a/fe/fe-core/src/main/java/org/apache/doris/common/util/PropertyAnalyzer.java b/fe/fe-core/src/main/java/org/apache/doris/common/util/PropertyAnalyzer.java index dd137077db..a2b35e13e4 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/common/util/PropertyAnalyzer.java +++ b/fe/fe-core/src/main/java/org/apache/doris/common/util/PropertyAnalyzer.java @@ -611,6 +611,8 @@ public class PropertyAnalyzer { return TCompressionType.LZ4; } else if (compressionType.equalsIgnoreCase("lz4f")) { return TCompressionType.LZ4F; + } else if (compressionType.equalsIgnoreCase("lz4hc")) { + return TCompressionType.LZ4HC; } else if (compressionType.equalsIgnoreCase("zlib")) { return TCompressionType.ZLIB; } else if (compressionType.equalsIgnoreCase("zstd")) { diff --git a/gensrc/thrift/AgentService.thrift b/gensrc/thrift/AgentService.thrift index f92f873fc4..13bee01da8 100644 --- a/gensrc/thrift/AgentService.thrift +++ b/gensrc/thrift/AgentService.thrift @@ -103,7 +103,8 @@ enum TCompressionType { LZ4 = 4, LZ4F = 5, ZLIB = 6, - ZSTD = 7 + ZSTD = 7, + LZ4HC = 8 } diff --git a/regression-test/data/compression_p0/load.csv b/regression-test/data/compression_p0/load.csv new file mode 100644 index 0000000000..c1706839bd --- /dev/null +++ b/regression-test/data/compression_p0/load.csv @@ -0,0 +1,5 @@ +1, 2, 3, 4, 5, 6, 2023-1-1, 2023-1-1, test, test, 1.0 +1, 2, 3, 4, 5, 6, 2023-1-1, 2023-1-1, test, test, 1.0 +1, 2, 3, 4, 5, 6, 2023-1-1, 2023-1-1, test, test, 1.0 +1, 2, 3, 4, 5, 6, 2023-1-1, 2023-1-1, test, test, 1.0 +1, 2, 3, 4, 5, 6, 2023-1-1, 2023-1-1, test, test, 1.0 \ No newline at end of file diff --git a/regression-test/data/compression_p0/load.out b/regression-test/data/compression_p0/load.out new file mode 100644 index 0000000000..a45b9d3948 --- /dev/null +++ b/regression-test/data/compression_p0/load.out @@ -0,0 +1,43 @@ +-- This file is automatically generated. You should know what you did if you want to edit this +-- !sql1 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + +-- !sql2 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + +-- !sql3 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + +-- !sql4 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + +-- !sql5 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + +-- !sql6 -- +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 +1 2 3 4 5 6 2023-01-01T00:00 2023-01-01 test test 1.000000000 + diff --git a/regression-test/data/compress_p1/snappy/ipv4.csv b/regression-test/data/compression_p1/ipv4.csv similarity index 100% rename from regression-test/data/compress_p1/snappy/ipv4.csv rename to regression-test/data/compression_p1/ipv4.csv diff --git a/regression-test/suites/compress_p1/snappy/load.groovy b/regression-test/suites/compress_p1/snappy/load.groovy deleted file mode 100644 index bbe76510c0..0000000000 --- a/regression-test/suites/compress_p1/snappy/load.groovy +++ /dev/null @@ -1,45 +0,0 @@ - -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -suite("test_snappy", "p1") { - def tableName = "test_snappy" - - // create table - sql """ DROP TABLE IF EXISTS ${tableName} """ - sql """ - CREATE TABLE IF NOT EXISTS ${tableName} ( - `k1` varchar(40) NULL - ) ENGINE=OLAP - DUPLICATE KEY(`k1`) - COMMENT 'OLAP' - DISTRIBUTED BY HASH(`k1`) BUCKETS 1 - PROPERTIES ("replication_allocation" = "tag.location.default: 1", - "compression" = "snappy"); - """ - - // skip 3 lines and file have 4 lines - streamLoad { - table "${tableName}" - - file 'ipv4.csv' - } - - sql "sync" - def count = sql "select count(*) from ${tableName} limit 10" - assertEquals(82845, count[0][0]) -} diff --git a/regression-test/suites/compression_p0/load.groovy b/regression-test/suites/compression_p0/load.groovy new file mode 100644 index 0000000000..70eeafea12 --- /dev/null +++ b/regression-test/suites/compression_p0/load.groovy @@ -0,0 +1,335 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +suite("test_compression", "p0") { + // test snappy compression algorithm + def tableName = "test_snappy" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "snappy" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql1 "select * from ${tableName} order by k1, k2" + + + // test LZ4 compression algorithm + tableName = "test_LZ4" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql2 "select * from ${tableName} order by k1, k2" + + + // test LZ4F compression algorithm + tableName = "test_LZ4F" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4F" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql3 "select * from ${tableName} order by k1, k2" + + + // test LZ4HC compression algorithm + tableName = "test_LZ4HC" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4HC" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql4 "select * from ${tableName} order by k1, k2" + + + // test ZLIB compression algorithm + tableName = "test_ZLIB" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "ZLIB" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql5 "select * from ${tableName} order by k1, k2" + + + // test ZSTD compression algorithm + tableName = "test_ZSTD" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` bigint(20) NULL, + `k2` tinyint(4) NULL, + `k3` smallint(6) NULL, + `k4` int(11) NULL, + `k5` bigint(20) NULL, + `k6` largeint(40) NULL, + `k7` datetime NULL, + `k8` date NULL, + `k9` char(10) NULL, + `k10` varchar(6) NULL, + `k11` decimal(27, 9) NULL + ) ENGINE=OLAP + Duplicate KEY(`k1`, `k2`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`, `k2`) BUCKETS 3 + PROPERTIES ( + "replication_allocation" = "tag.location.default: 1", + "compression" = "ZSTD" + ); + """ + + streamLoad { + table "${tableName}" + + set 'column_separator', ',' + set 'columns', 'k1, k2, k3, k4, k5, k6, k7, k8, k9, k10, k11' + + file 'load.csv' + time 10000 // limit inflight 10s + + check { result, exception, startTime, endTime -> + if (exception != null) { + throw exception + } + log.info("Stream load result: ${result}".toString()) + def json = parseJson(result) + assertEquals("success", json.Status.toLowerCase()) + assertEquals(5, json.NumberTotalRows) + assertEquals(0, json.NumberFilteredRows) + assertEquals(0, json.NumberUnselectedRows) + } + } + + sql "sync" + order_qt_sql6 "select * from ${tableName} order by k1, k2" +} \ No newline at end of file diff --git a/regression-test/suites/compression_p1/load.groovy b/regression-test/suites/compression_p1/load.groovy new file mode 100644 index 0000000000..64a1962a53 --- /dev/null +++ b/regression-test/suites/compression_p1/load.groovy @@ -0,0 +1,179 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +suite("test_compression_p1", "p1") { + // test snappy compression algorithm + def tableName = "test_snappy" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "snappy"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + def count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) + + + // test LZ4 compression algorithm + tableName = "test_LZ4" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) + + + // test LZ4F compression algorithm + tableName = "test_LZ4F" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4F"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) + + + // test LZ4HC compression algorithm + tableName = "test_LZ4HC" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "LZ4HC"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) + + + // test ZLIB compression algorithm + tableName = "test_ZLIB" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "ZLIB"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) + + + // test ZSTD compression algorithm + tableName = "test_ZSTD" + + sql """ DROP TABLE IF EXISTS ${tableName} """ + sql """ + CREATE TABLE IF NOT EXISTS ${tableName} ( + `k1` varchar(40) NULL + ) ENGINE=OLAP + DUPLICATE KEY(`k1`) + COMMENT 'OLAP' + DISTRIBUTED BY HASH(`k1`) BUCKETS 1 + PROPERTIES ("replication_allocation" = "tag.location.default: 1", + "compression" = "ZSTD"); + """ + + // skip 3 lines and file have 4 lines + streamLoad { + table "${tableName}" + + file 'ipv4.csv' + } + + sql "sync" + count = sql "select count(*) from ${tableName} limit 10" + assertEquals(82845, count[0][0]) +} \ No newline at end of file