You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/09/02 17:32:28 UTC

[GitHub] [flink] rmetzger commented on a change in pull request #13217: [FLINK-16866] Make job submission non-blocking

rmetzger commented on a change in pull request #13217:
URL: https://github.com/apache/flink/pull/13217#discussion_r482246102



##########
File path: flink-tests/src/test/java/org/apache/flink/test/example/failing/JobSubmissionFailsITCase.java
##########
@@ -80,19 +75,6 @@ private static JobGraph getWorkingJobGraph() {
 		return new JobGraph("Working testing job", jobVertex);
 	}
 
-	// --------------------------------------------------------------------------------------------
-
-	private final boolean detached;
-
-	public JobSubmissionFailsITCase(boolean detached) {
-		this.detached = detached;
-	}
-
-	@Parameterized.Parameters(name = "Detached mode = {0}")
-	public static Collection<Boolean[]> executionModes(){
-		return Arrays.asList(new Boolean[]{false},
-				new Boolean[]{true});
-	}

Review comment:
       We can not distinguish between detached and attached job submission anymore. All submissions are detached.
   
   This is the old code:
   ```java
   			if (detached) {
   				client.submitJob(jobGraph).get();
   			} else {
   				submitJobAndWaitForResult(client, jobGraph, getClass().getClassLoader());
   			}
   // method for reference:
   	public static void submitJobAndWaitForResult(ClusterClient<?> client, JobGraph jobGraph, ClassLoader classLoader) throws Exception {
   		client.submitJob(jobGraph)
   			.thenCompose(client::requestJobResult)
   			.get()
   			.toJobExecutionResult(classLoader);
   	}
   ```
   ... and with the non-blocking job submission, we would basically do the same in both cases.




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