flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GJL <...@git.apache.org>
Subject [GitHub] flink pull request #5437: [FLINK-8614] [flip6] Activate Flip-6 mode per defa...
Date Thu, 15 Feb 2018 12:37:08 GMT
Github user GJL commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5437#discussion_r168459950
  
    --- Diff: flink-runtime/src/main/java/org/apache/flink/runtime/dispatcher/Dispatcher.java
---
    @@ -402,6 +403,24 @@ public void start() throws Exception {
     		}
     	}
     
    +	@Override
    +	public CompletableFuture<JobResult> requestJobResult(JobID jobId, Time timeout)
{
    +		final JobManagerRunner jobManagerRunner = jobManagerRunners.get(jobId);
    +
    +		if (jobManagerRunner == null) {
    +			final ArchivedExecutionGraph archivedExecutionGraph = archivedExecutionGraphStore.get(jobId);
    +
    +			if (archivedExecutionGraph == null) {
    +				return FutureUtils.completedExceptionally(new FlinkJobNotFoundException(jobId));
    +			} else {
    +				return CompletableFuture.completedFuture(JobResult.createFrom(archivedExecutionGraph));
    +			}
    +		} else {
    +			return jobManagerRunner.getResultFuture().thenApply(
    --- End diff --
    
    nit: can be rewritten as `return jobManagerRunner.getResultFuture().thenApply(JobResult::createFrom);`


---

Mime
View raw message