flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [flink] zhijiangW commented on a change in pull request #9854: [FLINK-14230][task] Change the endInput call of the downstream operator to after the upstream operator closes
Date Mon, 28 Oct 2019 03:22:22 GMT
zhijiangW commented on a change in pull request #9854: [FLINK-14230][task] Change the endInput
call of the downstream operator to after the upstream operator closes
URL: https://github.com/apache/flink/pull/9854#discussion_r339391905
 
 

 ##########
 File path: flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/OperatorChain.java
 ##########
 @@ -244,46 +240,30 @@ public void prepareSnapshotPreBarrier(long checkpointId) throws Exception
{
 	}
 
 	/**
-	 * Ends an input (specified by {@code inputId}) of the {@link StreamTask}. The {@code inputId}
-	 * is numbered starting from 1, and `1` indicates the first input.
+	 * Ends the head operator input specified by  {@code inputId}).
 	 *
-	 * @param inputId The ID of the input.
-	 * @throws Exception if some exception happens in the endInput function of an operator.
+	 * @param inputId the input ID starts from 1 which indicates the first input.
 	 */
-	public void endInput(int inputId) throws Exception {
-		if (finishedInputs.areAllInputsSelected()) {
-			return;
-		}
-
-		if (headOperator instanceof TwoInputStreamOperator) {
-			if (finishedInputs.isInputSelected(inputId)) {
-				return;
-			}
+	public void endHeadOperatorInput(int inputId) throws Exception {
+		endOperatorInput(headOperator, inputId);
+	}
 
-			if (headOperator instanceof BoundedMultiInput) {
-				((BoundedMultiInput) headOperator).endInput(inputId);
-			}
+	/**
+	 * Ends all input of the non-head operator specified by {@code streamOperator})
 
 Review comment:
   nit: input -> inputs?

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message