wangyang0918 commented on PR #20673:
URL: https://github.com/apache/flink/pull/20673#issuecomment-1228046277

   @XComp Oh, my bad. I should not introduce this concurrent issue here. Either 
the `callbackInvocationCount` needs to be asserted in the whenComplete, or I 
should execute `CompletableFuture.supplyAsync` in the direct executor.
   
   ```
   result.whenComplete(
                   (ignore, throwable) -> 
assertThat(callbackInvocationCount.get(), is(2)));
   ```


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