XComp commented on a change in pull request #19041:
URL: https://github.com/apache/flink/pull/19041#discussion_r824500314



##########
File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/leaderretrieval/SettableLeaderRetrievalServiceTest.java
##########
@@ -32,6 +32,7 @@
 public class SettableLeaderRetrievalServiceTest extends TestLogger {
 
     private SettableLeaderRetrievalService settableLeaderRetrievalService;
+    private static final long TIMEOUT = 50L;

Review comment:
       On another note: Having low timeouts increases the risk of having flaky 
tests. I'm wondering whether we should go to something higher like 1 hour.

##########
File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/leaderretrieval/SettableLeaderRetrievalServiceTest.java
##########
@@ -32,6 +32,7 @@
 public class SettableLeaderRetrievalServiceTest extends TestLogger {
 
     private SettableLeaderRetrievalService settableLeaderRetrievalService;
+    private static final long TIMEOUT = 50L;

Review comment:
       ```suggestion
       private static final long TIMEOUT_IN_MILLIS = 50L;
   ```
   It's always a good habit to add the unit to variables like that. 
Alternatively, you could use Duration here and do initialize it with 
`Duration.ofHours()` to inialize it. In the test, you can then do 
`TIMEOUT.toMillis()`. That makes it clearer to the reader.




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to