You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ro...@apache.org on 2021/10/13 01:58:39 UTC
[iotdb] branch iotdb-1825 created (now 7e0ed33)
This is an automated email from the ASF dual-hosted git repository.
rong pushed a change to branch iotdb-1825
in repository https://gitbox.apache.org/repos/asf/iotdb.git.
at 7e0ed33 [IOTDB-1821][IOTDB-1825] IT fails on IoTDBTriggerExecutionIT & IoTDBContinuousQueryIT caused by connection broken
This branch includes the following new commits:
new 7e0ed33 [IOTDB-1821][IOTDB-1825] IT fails on IoTDBTriggerExecutionIT & IoTDBContinuousQueryIT caused by connection broken
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[iotdb] 01/01: [IOTDB-1821][IOTDB-1825] IT fails on
IoTDBTriggerExecutionIT & IoTDBContinuousQueryIT caused by connection
broken
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rong pushed a commit to branch iotdb-1825
in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit 7e0ed3381ececc2a05a5e5681aebf03836b67d32
Author: Steve Yurong Su <ro...@apache.org>
AuthorDate: Wed Oct 13 09:57:59 2021 +0800
[IOTDB-1821][IOTDB-1825] IT fails on IoTDBTriggerExecutionIT & IoTDBContinuousQueryIT caused by connection broken
---
.../db/integration/IoTDBContinuousQueryIT.java | 19 +++++-------------
.../db/integration/IoTDBTriggerExecutionIT.java | 23 ++++------------------
2 files changed, 9 insertions(+), 33 deletions(-)
diff --git a/server/src/test/java/org/apache/iotdb/db/integration/IoTDBContinuousQueryIT.java b/server/src/test/java/org/apache/iotdb/db/integration/IoTDBContinuousQueryIT.java
index 07d8ff7..a0cc4c7 100644
--- a/server/src/test/java/org/apache/iotdb/db/integration/IoTDBContinuousQueryIT.java
+++ b/server/src/test/java/org/apache/iotdb/db/integration/IoTDBContinuousQueryIT.java
@@ -57,22 +57,13 @@ public class IoTDBContinuousQueryIT {
Statement statement = connection.createStatement()) {
do {
for (String timeSeries : timeSeriesArray) {
- boolean isSuccessful = false;
- while (!isSuccessful) {
- try {
- statement.execute(
- String.format(
- "insert into %s(timestamp, temperature) values(now(), %.3f)",
- timeSeries, 200 * Math.random()));
- isSuccessful = true;
- } catch (SQLException throwable) {
- throwable.printStackTrace();
- fail(throwable.getMessage());
- }
- }
+ statement.execute(
+ String.format(
+ "insert into %s(timestamp, temperature) values(now(), %.3f)",
+ timeSeries, 200 * Math.random()));
}
} while (!isInterrupted());
- } catch (SQLException e) {
+ } catch (Exception e) {
exception = e;
}
}
diff --git a/server/src/test/java/org/apache/iotdb/db/integration/IoTDBTriggerExecutionIT.java b/server/src/test/java/org/apache/iotdb/db/integration/IoTDBTriggerExecutionIT.java
index b5fb623..dba1a90 100644
--- a/server/src/test/java/org/apache/iotdb/db/integration/IoTDBTriggerExecutionIT.java
+++ b/server/src/test/java/org/apache/iotdb/db/integration/IoTDBTriggerExecutionIT.java
@@ -68,25 +68,10 @@ public class IoTDBTriggerExecutionIT {
long count = 0;
do {
++count;
- boolean isSuccessful = false;
- while (!isSuccessful) {
- try {
- statement.execute(
- String.format(
- "insert into root.vehicle.d1(timestamp,s1,s2,s3,s4,s5,s6) values(%d,%d,%d,%d,%d,%s,\"%d\")",
- count,
- count,
- count,
- count,
- count,
- count % 2 == 0 ? "true" : "false",
- count));
- isSuccessful = true;
- } catch (SQLException throwable) {
- fail(throwable.getMessage());
- LOGGER.error(throwable.getMessage());
- }
- }
+ statement.execute(
+ String.format(
+ "insert into root.vehicle.d1(timestamp,s1,s2,s3,s4,s5,s6) values(%d,%d,%d,%d,%d,%s,\"%d\")",
+ count, count, count, count, count, count % 2 == 0 ? "true" : "false", count));
} while (!isInterrupted());
} catch (Exception e) {
exception = e;