You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "SzyWilliam (via GitHub)" <gi...@apache.org> on 2023/08/23 11:49:25 UTC

[GitHub] [iotdb] SzyWilliam opened a new pull request, #10942: [RatisConsensus] Fix flaky unit tests after linearizable read

SzyWilliam opened a new pull request, #10942:
URL: https://github.com/apache/iotdb/pull/10942

   (no comment)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [iotdb] OneSizeFitsQuorum merged pull request #10942: [RatisConsensus] Fix flaky unit tests after linearizable read

Posted by "OneSizeFitsQuorum (via GitHub)" <gi...@apache.org>.
OneSizeFitsQuorum merged PR #10942:
URL: https://github.com/apache/iotdb/pull/10942


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [iotdb] OneSizeFitsQuorum commented on a diff in pull request #10942: [RatisConsensus] Fix flaky unit tests after linearizable read

Posted by "OneSizeFitsQuorum (via GitHub)" <gi...@apache.org>.
OneSizeFitsQuorum commented on code in PR #10942:
URL: https://github.com/apache/iotdb/pull/10942#discussion_r1305542669


##########
iotdb-core/consensus/src/test/java/org/apache/iotdb/consensus/ratis/RecoverReadTest.java:
##########
@@ -175,21 +174,10 @@ public void consistentRead() throws Exception {
     miniCluster.waitUntilActiveLeader();
 
     // try max 3 minutes
-    final long startTs = System.currentTimeMillis();
-    DataSet resp;
-    try {
-      resp = TestUtils.doRead(miniCluster.getServer(0), gid);
-    } catch (ConsensusException e) {
-      final long timeElapsed = System.currentTimeMillis() - startTs;
-      if (timeElapsed > 1000 * 60 * 3) { // 3 min
-        Assert.fail("Linearizable read failed after 3 minutes, last exception seen: " + e);
-      }
-      Thread.sleep(100);
-      logger.info("linearizable read failed  when restart, retrying: ", e);
-      resp = TestUtils.doRead(miniCluster.getServer(0), gid);
-    }
+    final Timestamp startTs = Timestamp.currentTime();

Review Comment:
   seems that these two fields are useless?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org