zhijiangW commented on a change in pull request #8320: 
[FLINK-12201][network][metrics] Introduce InputGateWithMetrics in Task to 
increment numBytesIn metric
URL: https://github.com/apache/flink/pull/8320#discussion_r282821232
 
 

 ##########
 File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/taskmanager/Task.java
 ##########
 @@ -637,6 +636,11 @@ else if (current == ExecutionState.CANCELING) {
 
                        TaskKvStateRegistry kvStateRegistry = 
kvStateService.createKvStateTaskRegistry(jobId, getJobVertexId());
 
+                       InputGate[] gates = new InputGate[inputGates.length];
+                       for (int i = 0; i < inputGates.length; i++) {
 
 Review comment:
   Forgot another concern for not doing in the constructor. It would make 
maintain two arrays of `SingleInputGate` and `InputGate` separately. Because we 
still need to return the array of `SingleInputGate` for 
`NetworkEnvironment#setup` currently. What do you think?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to