This is an automated email from the ASF dual-hosted git repository.
jt2594838 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new 2838c35317f [Pipe] Stabilize receiver and compression integration
tests (#18644)
2838c35317f is described below
commit 2838c35317ff4c0fda0eaec78b141d08d6ee34d0
Author: Caideyipi <[email protected]>
AuthorDate: Wed Sep 16 12:17:54 2026 +0800
[Pipe] Stabilize receiver and compression integration tests (#18644)
---
.../treemodel/auto/enhanced/IoTDBPipeSinkCompressionIT.java | 12 ++++++------
.../apache/iotdb/pipe/it/single/IoTDBShowReceiversIT.java | 10 ++++++++--
2 files changed, 14 insertions(+), 8 deletions(-)
diff --git
a/integration-test/src/test/java/org/apache/iotdb/pipe/it/dual/treemodel/auto/enhanced/IoTDBPipeSinkCompressionIT.java
b/integration-test/src/test/java/org/apache/iotdb/pipe/it/dual/treemodel/auto/enhanced/IoTDBPipeSinkCompressionIT.java
index a695813fb9d..b5f4b55122d 100644
---
a/integration-test/src/test/java/org/apache/iotdb/pipe/it/dual/treemodel/auto/enhanced/IoTDBPipeSinkCompressionIT.java
+++
b/integration-test/src/test/java/org/apache/iotdb/pipe/it/dual/treemodel/auto/enhanced/IoTDBPipeSinkCompressionIT.java
@@ -192,12 +192,12 @@ public class IoTDBPipeSinkCompressionIT extends
AbstractPipeDualTreeModelAutoIT
TestUtils.executeNonQueries(
senderEnv,
Arrays.asList(
- "insert into root.db.d1(time, s1) values (now(), 3)",
- "insert into root.db.d1(time, s1) values (now(), 4)",
- "insert into root.db.d1(time, s1) values (now(), 5)",
- "insert into root.db.d1(time, s1) values (now(), 6)",
- "insert into root.db.d1(time, s1) values (now(), 7)",
- "insert into root.db.d1(time, s1) values (now(), 8)",
+ "insert into root.db.d1(time, s1) values (3, 3)",
+ "insert into root.db.d1(time, s1) values (4, 4)",
+ "insert into root.db.d1(time, s1) values (5, 5)",
+ "insert into root.db.d1(time, s1) values (6, 6)",
+ "insert into root.db.d1(time, s1) values (7, 7)",
+ "insert into root.db.d1(time, s1) values (8, 8)",
"flush"),
null);
diff --git
a/integration-test/src/test/java/org/apache/iotdb/pipe/it/single/IoTDBShowReceiversIT.java
b/integration-test/src/test/java/org/apache/iotdb/pipe/it/single/IoTDBShowReceiversIT.java
index 5e765d5677d..9bbdffb9fa8 100644
---
a/integration-test/src/test/java/org/apache/iotdb/pipe/it/single/IoTDBShowReceiversIT.java
+++
b/integration-test/src/test/java/org/apache/iotdb/pipe/it/single/IoTDBShowReceiversIT.java
@@ -99,7 +99,7 @@ public class IoTDBShowReceiversIT extends
AbstractPipeSingleIT {
@Test
public void testShowReceiversWithStoppedDataNode() throws Exception {
- Assert.assertTrue(env.getDataNodeWrapperList().size() >= 3);
+ ensureDataNodeCount(3);
createWriteBackPipe("root.show_receivers_ha", "show_receivers_ha_pipe");
assertShowReceivers("show receivers", BaseEnv.TREE_SQL_DIALECT,
"show_receivers_ha_pipe");
@@ -227,7 +227,7 @@ public class IoTDBShowReceiversIT extends
AbstractPipeSingleIT {
@Test
public void testReceiverRuntimeClearedAfterDataNodeRestartAndCanReconnect()
throws Exception {
- Assert.assertTrue(env.getDataNodeWrapperList().size() >= 2);
+ ensureDataNodeCount(2);
final int restartedDataNodeIndex = 0;
final DataNodeWrapper restartedDataNode =
env.getDataNodeWrapper(restartedDataNodeIndex);
final int restartedDataNodeId = getDataNodeId(restartedDataNode);
@@ -650,6 +650,12 @@ public class IoTDBShowReceiversIT extends
AbstractPipeSingleIT {
throw new AssertionError("Cannot find DataNodeId for " +
targetDataNode.getIpAndPortString());
}
+ private void ensureDataNodeCount(final int dataNodeCount) {
+ while (env.getDataNodeWrapperList().size() < dataNodeCount) {
+ env.registerNewDataNode(true);
+ }
+ }
+
private static String getString(
final ResultSet resultSet, final String treeColumnName, final String
tableColumnName)
throws SQLException {