public class DefaultExecutionSlotAllocator extends Object implements ExecutionSlotAllocator
ExecutionSlotAllocator
which will use SlotProvider
to allocate slots and
keep the unfulfilled requests for further cancellation.Constructor and Description |
---|
DefaultExecutionSlotAllocator(SlotProviderStrategy slotProviderStrategy,
InputsLocationsRetriever inputsLocationsRetriever) |
Modifier and Type | Method and Description |
---|---|
List<SlotExecutionVertexAssignment> |
allocateSlotsFor(List<ExecutionVertexSchedulingRequirements> executionVertexSchedulingRequirements)
Allocate slots for the given executions.
|
void |
cancel(ExecutionVertexID executionVertexId)
Cancel an ongoing slot request.
|
CompletableFuture<Void> |
stop()
Stop the allocator.
|
public DefaultExecutionSlotAllocator(SlotProviderStrategy slotProviderStrategy, InputsLocationsRetriever inputsLocationsRetriever)
public List<SlotExecutionVertexAssignment> allocateSlotsFor(List<ExecutionVertexSchedulingRequirements> executionVertexSchedulingRequirements)
ExecutionSlotAllocator
allocateSlotsFor
in interface ExecutionSlotAllocator
executionVertexSchedulingRequirements
- The requirements for scheduling the executions.public void cancel(ExecutionVertexID executionVertexId)
ExecutionSlotAllocator
cancel
in interface ExecutionSlotAllocator
executionVertexId
- identifying which slot request should be canceled.public CompletableFuture<Void> stop()
ExecutionSlotAllocator
stop
in interface ExecutionSlotAllocator
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.