final case class ZWorkerOptions extends Product with Serializable
Represents worker options
- See also
WorkerOptions
- Alphabetic
- By Inheritance
- ZWorkerOptions
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- val buildId: Option[String]
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- val defaultDeadlockDetectionTimeout: Option[zio.Duration]
- val defaultHeartbeatThrottleInterval: Option[zio.Duration]
- val disableEagerExecution: Option[Boolean]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val localActivityWorkerOnly: Option[Boolean]
- val maxConcurrentActivityExecutionSize: Option[Int]
- val maxConcurrentActivityTaskPollers: Option[Int]
- val maxConcurrentLocalActivityExecutionSize: Option[Int]
- val maxConcurrentWorkflowTaskExecutionSize: Option[Int]
- val maxConcurrentWorkflowTaskPollers: Option[Int]
- val maxHeartbeatThrottleInterval: Option[zio.Duration]
- val maxTaskQueueActivitiesPerSecond: Option[Double]
- val maxWorkerActivitiesPerSecond: Option[Double]
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- val stickyQueueScheduleToStartTimeout: Option[zio.Duration]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toJava: WorkerOptions
Converts worker options to Java SDK's WorkerOptions
- def toString(): String
- Definition Classes
- ZWorkerOptions → AnyRef → Any
- def transformJavaOptions(f: (Builder) => Builder): ZWorkerOptions
Allows to specify options directly on the java SDK's WorkerOptions.
Allows to specify options directly on the java SDK's WorkerOptions. Use it in case an appropriate
withXXX
method is missing- Note
the options specified via this method take precedence over those specified via other methods.
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- def withBuildId(value: String): ZWorkerOptions
Set a unique identifier for this worker.
Set a unique identifier for this worker. The identifier should be stable with respect to the code the worker uses for workflows, activities, and interceptors.
- def withDefaultDeadlockDetectionTimeout(value: zio.Duration): ZWorkerOptions
- value
time period in ms that will be used to detect workflows deadlock. Default is 1000ms, which is chosen if set to zero. Specifies an amount of time in milliseconds that workflow tasks are allowed to execute without interruption. If workflow task runs longer than specified interval without yielding (like calling an Activity), it will fail automatically.
- See also
io.temporal.internal.sync.PotentialDeadlockException
- def withDefaultHeartbeatThrottleInterval(value: zio.Duration): ZWorkerOptions
- value
the default amount of time between sending each pending heartbeat to the server. This is used if the ActivityOptions do not provide a HeartbeatTimeout. Otherwise, the interval becomes a value a bit smaller than the given HeartbeatTimeout. Default is 30s, which is chosen if set to null or 0.
- def withDisableEagerExecution(value: Boolean): ZWorkerOptions
Disable eager activities.
Disable eager activities. If set to true, eager execution will not be requested for activities requested from workflows bound to this Worker.
Eager activity execution means the server returns requested eager activities directly from the workflow task back to this worker which is faster than non-eager which may be dispatched to a separate worker.
Defaults to false, meaning that eager activity execution is permitted
- def withLocalActivityWorkerOnly(value: Boolean): ZWorkerOptions
If set to true worker would only handle workflow tasks and local activities.
If set to true worker would only handle workflow tasks and local activities. Non-local activities will not be executed by this worker.
Default is false.
- def withMaxConcurrentActivityExecutionSize(value: Int): ZWorkerOptions
- value
Maximum number of activities executed in parallel. Default is 200, which is chosen if set to zero.
- def withMaxConcurrentActivityTaskPollers(value: Int): ZWorkerOptions
Number of simultaneous poll requests on activity task queue.
Number of simultaneous poll requests on activity task queue. Consider incrementing if the worker is not throttled due to
MaxActivitiesPerSecond
orMaxConcurrentActivityExecutionSize
options and still cannot keep up with the request rate.Default is 5, which is chosen if set to zero.
- def withMaxConcurrentLocalActivityExecutionSize(value: Int): ZWorkerOptions
- value
Maximum number of local activities executed in parallel. Default is 200, which is chosen if set to zero.
- def withMaxConcurrentWorkflowTaskExecutionSize(value: Int): ZWorkerOptions
- value
Maximum number of simultaneously executed workflow tasks. Default is 200, which is chosen if set to zero. Note that this is not related to the total number of open workflows which do not need to be loaded in a worker when they are not making state transitions.
- def withMaxConcurrentWorkflowTaskPollers(value: Int): ZWorkerOptions
Sets the maximum number of simultaneous long poll requests to the Temporal Server to retrieve workflow tasks.
Sets the maximum number of simultaneous long poll requests to the Temporal Server to retrieve workflow tasks. Changing this value will affect the rate at which the worker is able to consume tasks from a task queue.
Due to internal logic where pollers alternate between sticky and non-sticky queues, this value cannot be 1 and will be adjusted to 2 if set to that value.
Default is 5, which is chosen if set to zero.
- def withMaxHeartbeatThrottleInterval(value: zio.Duration): ZWorkerOptions
- value
the maximum amount of time between sending each pending heartbeat to the server. Regardless of heartbeat timeout, no pending heartbeat will wait longer than this amount of time to send. Default is 60s, which is chosen if set to null or 0.
- def withMaxTaskQueueActivitiesPerSecond(value: Double): ZWorkerOptions
Optional: Sets the rate limiting on number of activities that can be executed per second.
Optional: Sets the rate limiting on number of activities that can be executed per second. This is managed by the server and controls activities per second for the entire task queue across all the workers. Notice that the number is represented in double, so that you can set it to less than 1 if needed. For example, set the number to 0.1 means you want your activity to be executed once every 10 seconds. This can be used to protect down stream services from flooding. The zero value of this uses the default value. Default is unlimited.
- def withMaxWorkerActivitiesPerSecond(value: Double): ZWorkerOptions
- value
Maximum number of activities started per second by this worker. Default is 0 which means unlimited. Note that this is a per worker limit. Use withMaxTaskQueueActivitiesPerSecond to set per task queue limit across multiple workers.
- def withStickyQueueScheduleToStartTimeout(value: zio.Duration): ZWorkerOptions
Timeout for a workflow task routed to the "sticky worker" - host that has the workflow instance cached in memory.
Timeout for a workflow task routed to the "sticky worker" - host that has the workflow instance cached in memory. Once it times out, then it can be picked up by any worker.
Default value is 5 seconds.
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)