Class ResourceBasedTuner.Builder
java.lang.Object
io.temporal.worker.tuning.ResourceBasedTuner.Builder
- Enclosing class:
ResourceBasedTuner
-
Method Summary
Modifier and TypeMethodDescriptionbuild()setActivitySlotOptions(ResourceBasedSlotOptions activitySlotOptions) Set the slot options for activity tasks.setControllerOptions(ResourceBasedControllerOptions controllerOptions) setExecutor(ScheduledExecutorService executor) Set the executor used for checking resource usage periodically.setLocalActivitySlotOptions(ResourceBasedSlotOptions localActivitySlotOptions) Set the slot options for local activity tasks.setNexusSlotOptions(ResourceBasedSlotOptions nexusSlotOptions) Set the slot options for nexus tasks.setWorkflowSlotOptions(ResourceBasedSlotOptions workflowSlotOptions) Set the slot options for workflow tasks.
-
Method Details
-
setControllerOptions
public ResourceBasedTuner.Builder setControllerOptions(ResourceBasedControllerOptions controllerOptions) -
setWorkflowSlotOptions
public ResourceBasedTuner.Builder setWorkflowSlotOptions(@Nonnull ResourceBasedSlotOptions workflowSlotOptions) Set the slot options for workflow tasks. Has no effect after the worker using this tuner starts.Defaults to minimum 5 slots, maximum 500 slots, and no ramp throttle.
-
setActivitySlotOptions
public ResourceBasedTuner.Builder setActivitySlotOptions(@Nonnull ResourceBasedSlotOptions activitySlotOptions) Set the slot options for activity tasks. Has no effect after the worker using this tuner starts.Defaults to minimum 1 slot, maximum 1000 slots, and 50ms ramp throttle.
-
setLocalActivitySlotOptions
public ResourceBasedTuner.Builder setLocalActivitySlotOptions(@Nonnull ResourceBasedSlotOptions localActivitySlotOptions) Set the slot options for local activity tasks. Has no effect after the worker using this tuner starts.Defaults to minimum 1 slot, maximum 1000 slots, and 50ms ramp throttle.
-
setNexusSlotOptions
public ResourceBasedTuner.Builder setNexusSlotOptions(@Nonnull ResourceBasedSlotOptions nexusSlotOptions) Set the slot options for nexus tasks. Has no effect after the worker using this tuner starts.Defaults to minimum 1 slot, maximum 1000 slots, and 50ms ramp throttle.
-
setExecutor
Set the executor used for checking resource usage periodically. Defaults to a two-thread pool. -
build
-