Pending Activities Limit

Temporal enforces a maximum of 50,000 pending Activities, Child Workflows, external Workflows, and Signals.

  1. A scheduled activity, a started (but not yet completed) activity, a failed activity (retriable), a wf waiting for cwf result, a wf waiting for a timer ends, a wf waiting for a signal. Are all of these considered pending activities?
  2. Can a running workflow execution (represented by 1 wfId) have more than 1 pending activities at the same time, such as in parallel/async activities execution?
  3. If I have 3 running workflow executions (3 unique wfIds), does it mean that I have at least 3 pending activities? If I have 50k running workflow executions, have I reached the maximum number of pending activities as limited by Temporal? Or does the 50k limit apply to each running workflow execution?
  1. Any activity invocation that is scheduled but has not completed yet (or failed or has timed out). So in workflow history any activities for which you have ActivityTaskScheduled event but not ActivityTaskStarted event (which denotes completion of the activity).

  2. Yes you can have multiple pending activities.

  3. It’s per single workflow execution

By the way I think the docs might need a bit of update, the knobs that you would specify in dynamic config are:

limit.numPendingChildExecutions.error
limit.numPendingActivities.error
limit.numPendingSignals.error
limit.numPendingCancelRequests.error