rkhachatryan commented on a change in pull request #17229:
URL: https://github.com/apache/flink/pull/17229#discussion_r738566486



##########
File path: 
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/StreamTask.java
##########
@@ -523,11 +534,15 @@ protected void 
processInput(MailboxDefaultAction.Controller controller) throws E
         if (!recordWriter.isAvailable()) {
             timer = new 
GaugePeriodTimer(ioMetrics.getBackPressuredTimePerSecond());
             resumeFuture = recordWriter.getAvailableFuture();
-        } else {
+        } else if (!inputProcessor.isAvailable()) {
             timer =
                     new ThroughputPeriodTimer(
                             ioMetrics.getIdleTimeMsPerSecond(), 
throughputCalculator);
             resumeFuture = inputProcessor.getAvailableFuture();
+        } else {
+            // todo: add new metrics (FLINK-23486)
+            timer = new 
GaugePeriodTimer(ioMetrics.getBackPressuredTimePerSecond());
+            resumeFuture = 
changelogWriterAvailabilityProvider.getAvailableFuture();

Review comment:
       I think in this PR/ticket it should be (2) (`backPressured = network + 
changelog`),
   and in FLINK-23486 a separate metric could be introduced, resulting in (1)




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