@Override public void notifyPartitionConsumable(JobID jobId, ResultPartitionID partitionId, final TaskActions taskActions) { Future<Acknowledge> acknowledgeFuture = jobMasterGateway.scheduleOrUpdateConsumers( jobMasterLeaderId, partitionId, timeout); acknowledgeFuture.exceptionallyAsync(new ApplyFunction<Throwable, Void>() { @Override public Void apply(Throwable value) { LOG.error("Could not schedule or update consumers at the JobManager.", value); taskActions.failExternally(new RuntimeException("Could not notify JobManager to schedule or update consumers.", value)); return null; } }, executor); } }
@Override public void notifyPartitionConsumable(JobID jobId, ResultPartitionID partitionId, final TaskActions taskActions) { CompletableFuture<Acknowledge> acknowledgeFuture = jobMasterGateway.scheduleOrUpdateConsumers(partitionId, timeout); acknowledgeFuture.whenCompleteAsync( (Acknowledge ack, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not schedule or update consumers at the JobManager.", throwable); taskActions.failExternally(new RuntimeException("Could not notify JobManager to schedule or update consumers.", throwable)); } }, executor); }
@Override public void notifyPartitionConsumable(JobID jobId, ResultPartitionID partitionId, final TaskActions taskActions) { CompletableFuture<Acknowledge> acknowledgeFuture = jobMasterGateway.scheduleOrUpdateConsumers(partitionId, timeout); acknowledgeFuture.whenCompleteAsync( (Acknowledge ack, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not schedule or update consumers at the JobManager.", throwable); taskActions.failExternally(new RuntimeException("Could not notify JobManager to schedule or update consumers.", throwable)); } }, executor); } }
@Override public void notifyPartitionConsumable(JobID jobId, ResultPartitionID partitionId, final TaskActions taskActions) { CompletableFuture<Acknowledge> acknowledgeFuture = jobMasterGateway.scheduleOrUpdateConsumers(partitionId, timeout); acknowledgeFuture.whenCompleteAsync( (Acknowledge ack, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not schedule or update consumers at the JobManager.", throwable); taskActions.failExternally(new RuntimeException("Could not notify JobManager to schedule or update consumers.", throwable)); } }, executor); } }