public class MappingWorksheet extends ObjectDefines a mapping problem for answering "where do we execute this task?"
The heart of the placement problem is a mapping problem. We are given a
Queue.Task, (which in the general case consists of a set of
SubTasks), and we are also given a number of idle
Executors, and our goal is to find a mapping from the former to the latter, which determines where each
This mapping is done under the following constraints:
"Same node" constraint. Some of the subtasks need to be co-located on the same node.
SubTasks can specify that it can be only run on nodes that has the label.
We first fold the former constraint into the problem definition. That is, we now consider a set of
SubTasks that need to be co-located as a single
MappingWorksheet.WorkChunk. Similarly, we consider a set of all
Executors from the same node as
MappingWorksheet.ExecutorChunk. Now, the problem becomes the weighted matching problem from
An instance of
MappingWorksheetcaptures a problem definition, plus which
MappingWorksheet.WorkChunkare compatible. The purpose of this class (and
MappingWorksheet.WorkChunk) are to expose a lot of convenience methods to assist various algorithms that produce the solution of this mapping problem, which is represented as
- Kohsuke Kawaguchi
- See Also:
- "Same node" constraint. Some of the subtasks need to be co-located on the same node. See
Nested Class Summary
Nested Classes Modifier and Type Class Description
MappingWorksheet.MappingRepresents the solution to the mapping problem.
SubTasks that need to run on the same node.
Constructors Constructor Description
MappingWorksheet(Queue.BuildableItem item, List<? extends MappingWorksheet.ExecutorSlot> offers)
MappingWorksheet(Queue.BuildableItem item, List<? extends MappingWorksheet.ExecutorSlot> offers, Collection<? extends LoadPredictor> loadPredictors)
All Methods Instance Methods Concrete Methods Modifier and Type Method Description
public MappingWorksheet(Queue.BuildableItem item, List<? extends MappingWorksheet.ExecutorSlot> offers)