dawidwys commented on a change in pull request #34:
URL: https://github.com/apache/flink-benchmarks/pull/34#discussion_r724225433



##########
File path: 
src/main/java/org/apache/flink/benchmark/CheckpointingTimeBenchmark.java
##########
@@ -284,8 +262,9 @@ protected int getNumberOfSlotsPerTaskManager() {
      */
     public static class SlowDiscardSink<T> implements SinkFunction<T> {
         @Override
-        public void invoke(T value, Context context) throws Exception {
-            Thread.sleep(1);
+        public void invoke(T value, Context context) {
+            final long startTime = System.nanoTime();
+            while (System.nanoTime() - startTime < 200_000) {}

Review comment:
       I replaced `Thread.sleep` with busy waiting. It improves saturation of 
network exchanges. With `Thread.sleep(1)` most of the unaligned checkpoints had 
no persisted in-flight data.




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