Skip to content

Commit f296874

Browse files
committed
Tune Edge compaction and TsFile defaults (#18566)
(cherry picked from commit 05a97b9)
1 parent c4ccfc7 commit f296874

2 files changed

Lines changed: 33 additions & 1 deletion

File tree

‎integration-test/src/test/java/org/apache/iotdb/edge/it/IoTDBEdgeBasicIT.java‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,18 @@ private static Connection openTableConnection() throws SQLException {
195195
@Test
196196
public void testPackagedConfiguration() throws Exception {
197197
assertFalse(PACKAGED_SYSTEM_PROPERTIES.containsKey("model_inference_execution_thread_count"));
198+
assertEdgeProperty("candidate_compaction_task_queue_size", "10");
199+
assertEdgeProperty("compaction_max_aligned_series_num_in_one_batch", "2");
200+
assertEdgeProperty("target_compaction_file_size", "33554432");
201+
assertEdgeProperty("inner_compaction_total_file_size_threshold", "52428800");
202+
assertEdgeProperty("inner_compaction_total_file_num_threshold", "10");
203+
assertEdgeProperty("inner_compaction_candidate_file_num", "8");
204+
assertEdgeProperty("max_cross_compaction_candidate_file_num", "10");
205+
assertEdgeProperty("max_cross_compaction_candidate_file_size", "52428800");
206+
assertEdgeProperty("target_chunk_point_num", "10000");
207+
assertEdgeProperty("target_chunk_size", "262144");
208+
assertEdgeProperty("max_number_of_points_in_page", "1000");
209+
assertEdgeProperty("page_size_in_byte", "16384");
198210
assertTrue(Files.isRegularFile(edgeHome.resolve("sbin/windows/check-edge.ps1")));
199211

200212
final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
@@ -217,6 +229,13 @@ public void testPackagedConfiguration() throws Exception {
217229
}
218230
}
219231

232+
private static void assertEdgeProperty(final String name, final String expectedValue) {
233+
assertEquals(
234+
"Unexpected packaged Edge value for " + name,
235+
expectedValue,
236+
PACKAGED_SYSTEM_PROPERTIES.getProperty(name));
237+
}
238+
220239
private static String jdbcUrl() {
221240
return Config.IOTDB_URL_PREFIX + "127.0.0.1:" + rpcPort;
222241
}

‎iotdb-core/node-commons/src/assembly/resources/conf/edge/iotdb-system.properties‎

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,12 +103,25 @@ max_allowed_concurrent_queries=100
103103
# ---- memory / file buffers ----
104104
wal_buffer_size_in_byte=1048576
105105
group_size_in_byte=4194304
106-
target_compaction_file_size=134217728
106+
target_chunk_point_num=10000
107+
target_chunk_size=262144
108+
page_size_in_byte=16384
109+
max_number_of_points_in_page=1000
107110
into_operation_buffer_size_in_byte=8388608
108111
batch_size=10000
109112
schema_region_ratis_log_appender_buffer_size_max=4194304
110113
config_node_ratis_log_appender_buffer_size_max=4194304
111114

115+
# ---- compaction working set ----
116+
candidate_compaction_task_queue_size=10
117+
compaction_max_aligned_series_num_in_one_batch=2
118+
target_compaction_file_size=33554432
119+
inner_compaction_total_file_size_threshold=52428800
120+
inner_compaction_total_file_num_threshold=10
121+
inner_compaction_candidate_file_num=8
122+
max_cross_compaction_candidate_file_num=10
123+
max_cross_compaction_candidate_file_size=52428800
124+
112125
# ---- background io politeness (share disks with other processes) ----
113126
compaction_write_throughput_mb_per_sec=8
114127
partition_table_recover_max_read_mb_per_sec=5

0 commit comments

Comments
 (0)