flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mxm <...@git.apache.org>
Subject [GitHub] flink pull request: [FLINK-2797][cli] Add support for running jobs...
Date Tue, 03 Nov 2015 14:09:05 GMT
Github user mxm commented on a diff in the pull request:

    https://github.com/apache/flink/pull/1214#discussion_r43750488
  
    --- Diff: flink-streaming-java/src/main/java/org/apache/flink/streaming/api/environment/StreamContextEnvironment.java
---
    @@ -81,13 +60,13 @@ public JobExecutionResult execute(String jobName) throws Exception
{
     
     		transformations.clear();
     
    -		// execute the programs
    -		if (wait) {
    -			return client.runBlocking(streamGraph, jars, classpaths, userCodeClassLoader);
    +		if (ctx.isWait()) {
    +			return ctx.getClient().runBlocking(streamGraph, ctx.getJars(), ctx.getClasspaths(),
    +					ctx.getUserCodeClassLoader());
     		} else {
    -			JobSubmissionResult result = client.runDetached(streamGraph, jars, classpaths, userCodeClassLoader);
    +			ctx.setCurrentPlan(streamGraph);
     			LOG.warn("Job was executed in detached mode, the results will be available on completion.");
    -			return JobExecutionResult.fromJobSubmissionResult(result);
    +			return ContextEnvironment.DetachedJobExecutionResult.INSTANCE;
    --- End diff --
    
    Could you add a comment here which explains why you delay the execution?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message