XComp commented on code in PR #20811:
URL: https://github.com/apache/flink/pull/20811#discussion_r968246747


##########
flink-runtime/src/test/java/org/apache/flink/runtime/dispatcher/DefaultJobManagerRunnerRegistryTest.java:
##########
@@ -200,14 +197,36 @@ public void testFailingLocalCleanupAsync() throws 
Exception {
                 .failsWithin(Duration.ZERO)
                 .withThrowableOfType(ExecutionException.class)
                 .extracting(FlinkAssertions::chainOfCauses, 
FlinkAssertions.STREAM_THROWABLE)
-                .hasExactlyElementsOfTypes(
-                        ExecutionException.class,
-                        FlinkException.class,
-                        expectedException.getClass())
+                .hasExactlyElementsOfTypes(ExecutionException.class, 
expectedException.getClass())
                 .last()
                 .isEqualTo(expectedException);
     }
 
+    @Test
+    public void testLocalCleanupAsyncNonBlocking() {
+        final TestingJobManagerRunner jobManagerRunner =
+                
TestingJobManagerRunner.newBuilder().setBlockingTermination(true).build();
+        testInstance.register(jobManagerRunner);
+
+        // this call would block
+        final CompletableFuture<Void> cleanupFuture =
+                Assertions.assertTimeoutPreemptively(
+                        Duration.ofMinutes(10),

Review Comment:
   I had your words already in the back of my head when implementing it that 
way. But I kind of was certain that in this specific case, it would better to 
have it. :innocent:  But you're right - there's no real reasoning for not 
sticking to the policy...



-- 
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