Class TaskAssignmentUtils.RackAwareOptimizationParams
java.lang.Object
org.apache.kafka.streams.processor.assignment.TaskAssignmentUtils.RackAwareOptimizationParams
- Enclosing class:
- TaskAssignmentUtils
A simple config container for necessary parameters and optional overrides to apply when
running the active or standby task rack-aware optimizations.
-
Method Summary
Modifier and TypeMethodDescriptionReturn a new config object with the tasksToOptimize set to all stateful tasks in the given ApplicationStateReturn a new config object with the tasksToOptimize set to all stateless tasks in the given ApplicationStateReturn a new config object with the provided tasksToOptimizeof
(ApplicationState applicationState) Return a new config object with no overrides and the tasksToOptimize initialized to the set of all tasks in the given ApplicationStatewithNonOverlapCostOverride
(int nonOverlapCostOverride) Return a new config object with the provided nonOverlapCost override appliedwithTrafficCostOverride
(int trafficCostOverride) Return a new config object with the provided trafficCost override applied
-
Method Details
-
of
Return a new config object with no overrides and the tasksToOptimize initialized to the set of all tasks in the given ApplicationState -
forStatefulTasks
Return a new config object with the tasksToOptimize set to all stateful tasks in the given ApplicationState -
forStatelessTasks
Return a new config object with the tasksToOptimize set to all stateless tasks in the given ApplicationState -
forTasks
Return a new config object with the provided tasksToOptimize -
withTrafficCostOverride
public TaskAssignmentUtils.RackAwareOptimizationParams withTrafficCostOverride(int trafficCostOverride) Return a new config object with the provided trafficCost override applied -
withNonOverlapCostOverride
public TaskAssignmentUtils.RackAwareOptimizationParams withNonOverlapCostOverride(int nonOverlapCostOverride) Return a new config object with the provided nonOverlapCost override applied
-