Class PreferredAllocationRequestSlotMatchingStrategy
- java.lang.Object
-
- org.apache.flink.runtime.jobmaster.slotpool.PreferredAllocationRequestSlotMatchingStrategy
-
- All Implemented Interfaces:
RequestSlotMatchingStrategy
public class PreferredAllocationRequestSlotMatchingStrategy extends Object implements RequestSlotMatchingStrategy
RequestSlotMatchingStrategythat takes the preferred allocations into account. The strategy will try to fulfill the preferred allocations and if this is not possible, then it will fall back torollbackStrategy.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.flink.runtime.jobmaster.slotpool.RequestSlotMatchingStrategy
RequestSlotMatchingStrategy.RequestSlotMatch
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static RequestSlotMatchingStrategycreate(RequestSlotMatchingStrategy rollbackStrategy)booleanequals(Object o)Collection<RequestSlotMatchingStrategy.RequestSlotMatch>matchRequestsAndSlots(Collection<? extends PhysicalSlot> slots, Collection<org.apache.flink.runtime.jobmaster.slotpool.PendingRequest> pendingRequests, Map<ResourceID,LoadingWeight> taskExecutorsLoadingWeight)Match the given slots with the given collection of pending requests.StringtoString()
-
-
-
Method Detail
-
create
public static RequestSlotMatchingStrategy create(RequestSlotMatchingStrategy rollbackStrategy)
-
matchRequestsAndSlots
public Collection<RequestSlotMatchingStrategy.RequestSlotMatch> matchRequestsAndSlots(Collection<? extends PhysicalSlot> slots, Collection<org.apache.flink.runtime.jobmaster.slotpool.PendingRequest> pendingRequests, Map<ResourceID,LoadingWeight> taskExecutorsLoadingWeight)
Description copied from interface:RequestSlotMatchingStrategyMatch the given slots with the given collection of pending requests.- Specified by:
matchRequestsAndSlotsin interfaceRequestSlotMatchingStrategy- Parameters:
slots- slots to matchpendingRequests- slot requests to matchtaskExecutorsLoadingWeight- current task executors loading weight information- Returns:
- resulting matches of this operation
-
-