public interface IScheduler
| Modifier and Type | Method and Description |
|---|---|
default List<org.apache.pulsar.functions.proto.Function.Assignment> |
rebalance(List<org.apache.pulsar.functions.proto.Function.Assignment> currentAssignments,
Set<String> workers)
Rebalances function instances scheduled to workers
|
List<org.apache.pulsar.functions.proto.Function.Assignment> |
schedule(List<org.apache.pulsar.functions.proto.Function.Instance> unassignedFunctionInstances,
List<org.apache.pulsar.functions.proto.Function.Assignment> currentAssignments,
Set<String> workers)
Scheduler schedules assignments to appropriate workers and adds into #resultAssignments
|
List<org.apache.pulsar.functions.proto.Function.Assignment> schedule(List<org.apache.pulsar.functions.proto.Function.Instance> unassignedFunctionInstances, List<org.apache.pulsar.functions.proto.Function.Assignment> currentAssignments, Set<String> workers)
unassignedFunctionInstances - all unassigned instancescurrentAssignments - current assignmentsworkers - current list of active workersdefault List<org.apache.pulsar.functions.proto.Function.Assignment> rebalance(List<org.apache.pulsar.functions.proto.Function.Assignment> currentAssignments, Set<String> workers)
currentAssignments - current assignmentsworkers - current list of active workersCopyright © 2017–2022 Apache Software Foundation. All rights reserved.