Menu
Amazon Simple Workflow Service
Developer Guide (API Version 2012-01-25)

Amazon SWF Limits

Amazon SWF places limits on the sizes of certain workflow parameters, such as on the number of domains per account and on the size of the workflow execution history. These limits are designed to prevent erroneous workflows from consuming all of the resources of the system, but are not hard limits. If you find that your application is frequently exceeding these limits, you can request a service limit increase.

General Account Limits for Amazon SWF

  • Maximum registered domains – 100

    This limit includes both registered and deprecated domains.

  • Maximum workflow and activity types – 10,000 each per domain

    This limit includes both registered and deprecated types.

  • API call limit – Beyond infrequent spikes, applications may be throttled if they make a large number of API calls in a very short period of time.

  • Maximum request size – 1 MB per request

    This is the total data size per Amazon SWF API request, including the request header and all other associated request data.

Limits on Workflow Executions

  • Maximum open workflow executions – 100,000 per domain

    This count includes child workflow executions.

  • Maximum workflow execution time – 1 year

  • Maximum workflow execution history size – 25,000 events

    Best practice is to structure each workflow such that its history does not grow beyond 10,000 events. Since the decider has to fetch the workflow history, a smaller history allows the decider to complete more quickly. If using the Flow Framework, you can use ContinueAsNew to continue a workflow with a fresh history.

  • Maximum child workflow executions – 1,000 per workflow execution

  • Workflow execution idle time limit – 1 year (constrained by workflow execution time limit)

    You can configure workflow timeouts to cause a timeout event to occur if a particular stage of your workflow takes too long.

  • Workflow retention time limit – 90 days

    After this time, the workflow history can no longer be retrieved or viewed. There is no further limit to the number of closed workflow executions that are retained by Amazon SWF.

If your use case requires you to go beyond these limits, you can use features Amazon SWF provides to continue executions and structure your applications using child workflow executions. If you find that you still need a limits increase, see Requesting a Limit Increase.

Limits on Task Executions

  • Maximum pollers per task list – 1,000 per task list

    You can have a maximum of 1,000 pollers which simultaneously poll a particular task list. If you go over 1,000, you receive a LimitExceededException.

    Note

    While the maximum is 1,000, you might encounter LimitExceededException errors well before this limit. To reduce these errors, use multiple task lists to distribute polling.

  • Maximum task execution time – 1 year (constrained by workflow execution time limit)

    You can configure activity timeouts to cause a timeout event to occur if a particular stage of your activity task execution takes too long.

  • Maximum time SWF will keep a task in the queue – 1 year (constrained by workflow execution time limit)

    You can configure default activity timeouts during activity registration that will cause a timeout event to occur if a particular stage of your activity task execution takes too long. You can also override the default activity timeouts when you schedule an activity task in your decider code.

  • Maximum open activity tasks – 1,000 per workflow execution.

    This limit includes both activity tasks that have been scheduled and those being processed by workers.

  • Maximum open timers – 1,000 per workflow execution

  • Maximum input/result data size – 32,768 characters

    This limit affects activity or workflow execution result data, input data when scheduling activity tasks or workflow executions, and input sent with a workflow execution signal.

  • Maximum decisions in a decision task response – varies

    Due to the 1 MB limit on the maximum API request size, the number of decisions returned in a single call to RespondDecisionTaskCompleted will be limited according to the size of the data used by each decision, including the size of any input data provided to scheduled activity tasks or to workflow executions.

Amazon SWF throttling limits

In addition to the service limits described previously, certain Amazon SWF API calls and decision events are throttled to maintain service bandwidth, using a token bucket scheme. If your rate of requests consistently exceeds the rates that are listed here, you can request a throttle limit increase.

Throttling limits are per account / region. Different regions have different throttling limits based on their size.

Throttling Limits for Small Regions
  • US East (Ohio) Region

  • US West (Oregon) Region

  • Canada (Central) Region

  • Asia Pacific (Seoul) Region

  • Asia Pacific (Mumbai) Region

  • China (Ningxia) Region

  • EU (Frankfurt) Region

  • EU (Ireland) Region

  • EU (London) Region

Throttling Limits for Medium Regions
  • Asia Pacific (Tokyo) Region

  • Asia Pacific (Singapore) Region

  • Asia Pacific (Sydney) Region

  • China (Beijing) Region

  • South America (São Paulo) Region

  • US West (N. California) Region

Throttling Limits for Large Regions
  • US East (N. Virginia) Region

The following sections list the throttling limits for each of these groups of regions.

Throttling Limits for Small Regions

API name Bucket size Refill rate / s
CountClosedWorkflowExecutions 1000 1
CountOpenWorkflowExecutions 1000 1
CountPendingActivityTasks 100 1
CountPendingDecisionTasks 100 1
DeprecateActivityType 100 1
DeprecateDomain 50 1
DeprecateWorkflowType 100 1
DescribeActivityType 1000 1
DescribeDomain 1000 1
DescribeWorkflowExecution 1000 1
DescribeWorkflowType 1000 1
GetWorkflowExecutionHistory 1000 5
ListActivityTypes 100 1
ListClosedWorkflowExecutions 100 1
ListDomains 50 1
ListOpenWorkflowExecutions 100 1
ListWorkflowTypes 100 1
PollForActivityTask 1000 10
PollForDecisionTask 1000 12
RecordActivityTaskHeartbeat 1000 1
RegisterActivityType 100 1
RegisterDomain 50 1
RegisterWorkflowType 100 1
RequestCancelWorkflowExecution 1000 5
RespondActivityTaskCanceled 1000 10
RespondActivityTaskCompleted 1000 10
RespondActivityTaskFailed 1000 10
RespondDecisionTaskCompleted 1000 12
SignalWorkflowExecution 1000 5
StartWorkflowExecution 1000 2
TerminateWorkflowExecution 1000 10

Decision limits

Decision Bucket size Refill rate / s
RequestCancelExternalWorkflowExecution 100 10
ScheduleActivityTask 100 10
SignalExternalWorkflowExecution 100 10
StartChildWorkflowExecution 100 2
StartTimer 500 25

Throttling Limits for Medium Regions

API name Bucket size Refill rate / s
CountClosedWorkflowExecutions 2000 2
CountOpenWorkflowExecutions 2000 2
CountPendingActivityTasks 200 2
CountPendingDecisionTasks 200 2
DeprecateActivityType 200 2
DeprecateDomain 100 2
DeprecateWorkflowType 200 2
DescribeActivityType 2000 2
DescribeDomain 200 2
DescribeWorkflowExecution 2000 2
DescribeWorkflowType 2000 2
GetWorkflowExecutionHistory 2000 10
ListActivityTypes 200 2
ListClosedWorkflowExecutions 200 2
ListDomains 100 2
ListOpenWorkflowExecutions 200 2
ListWorkflowTypes 200 2
PollForActivityTask 2000 20
PollForDecisionTask 2000 24
RecordActivityTaskHeartbeat 2000 2
RegisterActivityType 200 2
RegisterDomain 100 2
RegisterWorkflowType 200 2
RequestCancelWorkflowExecution 2000 10
RespondActivityTaskCanceled 2000 20
RespondActivityTaskCompleted 2000 20
RespondActivityTaskFailed 1000 10
RespondDecisionTaskCompleted 2000 24
SignalWorkflowExecution 2000 10
StartWorkflowExecution 2000 4
TerminateWorkflowExecution 2000 20

Decision limits

Decision Bucket size Refill rate / s
RequestCancelExternalWorkflowExecution 200 20
ScheduleActivityTask 200 20
SignalExternalWorkflowExecution 200 20
StartChildWorkflowExecution 200 4
StartTimer 1000 50

Throttling Limits for Large Regions

API name Bucket size Refill rate / s
CountClosedWorkflowExecutions 1000 1
CountOpenWorkflowExecutions 1000 1
CountPendingActivityTasks 100 1
CountPendingDecisionTasks 100 1
DeprecateActivityType 100 1
DeprecateDomain 50 1
DeprecateWorkflowType 100 1
DescribeActivityType 1000 1
DescribeDomain 100 1
DescribeWorkflowExecution 1000 1
DescribeWorkflowType 1000 1
GetWorkflowExecutionHistory 1000 5
ListActivityTypes 100 1
ListClosedWorkflowExecutions 100 1
ListDomains 50 1
ListOpenWorkflowExecutions 100 1
ListWorkflowTypes 100 1
PollForActivityTask 1000 100
PollForDecisionTask 1000 142
RecordActivityTaskHeartbeat 1000 1
RegisterActivityType 100 1
RegisterDomain 50 1
RegisterWorkflowType 100 1
RequestCancelWorkflowExecution 1000 5
RespondActivityTaskCanceled 1000 100
RespondActivityTaskCompleted 1000 100
RespondActivityTaskFailed 1000 100
RespondDecisionTaskCompleted 1000 142
SignalWorkflowExecution 1000 5
StartWorkflowExecution 1000 25
TerminateWorkflowExecution 1000 10

Decision limits

Decision Bucket size Refill rate / s
RequestCancelExternalWorkflowExecution 100 10
ScheduleActivityTask 500 100
SignalExternalWorkflowExecution 500 10
StartChildWorkflowExecution 500 2
StartTimer 1000 142

Requesting a Limit Increase

Use the Support Center page in the AWS Management Console to request a limit increase for resources provided by AWS Step Functions on a per-region basis. For more information, see To Request a Limit Increase in the AWS General Reference.