---
title: Amazon SWF
description: >-
  Amazon SWF helps developers build, run, and scale background jobs that have
  parallel or sequential steps.
breadcrumbs: Docs > Integrations > Amazon SWF
---

# Amazon SWF
Integration version1.0.0
## Overview{% #overview %}

Amazon SWF helps developers build, run, and scale background jobs that have parallel or sequential steps.

Enable this integration to see in Datadog all your SWF metrics.

## Setup{% #setup %}

### Installation{% #installation %}

If you haven't already, set up the [Amazon Web Services integration](https://docs.datadoghq.com/integrations/amazon_web_services/) first.

### Metric collection{% #metric-collection %}

1. In the [AWS integration page](https://app.datadoghq.com/integrations/amazon-web-services), ensure that `SWF` is enabled under the `Metric Collection` tab.
1. Install the [Datadog - Amazon SWF integration](https://app.datadoghq.com/integrations/amazon-swf).

### Log collection{% #log-collection %}

#### Enable logging{% #enable-logging %}

Configure Amazon SWF to send logs either to a S3 bucket or to CloudWatch.

**Note**: If you log to a S3 bucket, make sure that `amazon_swf` is set as *Target prefix*.

#### Send logs to Datadog{% #send-logs-to-datadog %}

1. If you haven't already, set up the [Datadog Forwarder Lambda function](https://docs.datadoghq.com/logs/guide/forwarder/).

1. Once the Lambda function is installed, manually add a trigger on the S3 bucket or CloudWatch log group that contains your Amazon SWF logs in the AWS console:

   - [Add a manual trigger on the S3 bucket](https://docs.datadoghq.com/logs/guide/send-aws-services-logs-with-the-datadog-lambda-function/#collecting-logs-from-s3-buckets)
   - [Add a manual trigger on the CloudWatch Log Group](https://docs.datadoghq.com/logs/guide/send-aws-services-logs-with-the-datadog-lambda-function/#collecting-logs-from-cloudwatch-log-group)

## Data Collected{% #data-collected %}

### Metrics{% #metrics %}

|  |
|  |
| **aws.swf.activity\_task\_schedule\_to\_close\_time**(gauge)           | The time interval, in milliseconds, between the time when the activity was scheduled to when it closed.*Shown as millisecond*                                              |
| **aws.swf.activity\_task\_schedule\_to\_close\_time.maximum**(gauge)   | Maximum time interval, in milliseconds, between the time when the activity was scheduled to when it closed.*Shown as millisecond*                                          |
| **aws.swf.activity\_task\_schedule\_to\_close\_time.minimum**(gauge)   | Minimum time interval, in milliseconds, between the time when the activity was scheduled to when it closed.*Shown as millisecond*                                          |
| **aws.swf.activity\_task\_schedule\_to\_start\_time**(gauge)           | The time interval, in milliseconds, between the time when the activity task was scheduled and when it started.*Shown as millisecond*                                       |
| **aws.swf.activity\_task\_schedule\_to\_start\_time.maximum**(gauge)   | Maximum time interval, in milliseconds, between the time when the activity task was scheduled and when it started.*Shown as millisecond*                                   |
| **aws.swf.activity\_task\_schedule\_to\_start\_time.minimum**(gauge)   | Minimum time interval, in milliseconds, between the time when the activity task was scheduled and when it started.*Shown as millisecond*                                   |
| **aws.swf.activity\_task\_start\_to\_close\_time**(gauge)              | The time interval, in milliseconds, between the time that the decision task was started and the time it was closed.*Shown as millisecond*                                  |
| **aws.swf.activity\_task\_start\_to\_close\_time.maximum**(gauge)      | Maximum time interval, in milliseconds, between the time that the decision task was started and the time it was closed.*Shown as millisecond*                              |
| **aws.swf.activity\_task\_start\_to\_close\_time.minimum**(gauge)      | Minimum time interval, in milliseconds, between the time that the decision task was started and the time it was closed.*Shown as millisecond*                              |
| **aws.swf.activity\_tasks\_canceled**(count)                           | The count of activity tasks that were canceled.                                                                                                                            |
| **aws.swf.activity\_tasks\_completed**(count)                          | The count of activity tasks that completed.                                                                                                                                |
| **aws.swf.activity\_tasks\_failed**(count)                             | The count of activity tasks that failed.                                                                                                                                   |
| **aws.swf.consumed\_capacity**(count)                                  | The count of requests per second.*Shown as request*                                                                                                                        |
| **aws.swf.decision\_task\_schedule\_to\_start\_time**(gauge)           | The time interval, in milliseconds, between the time that the decision task was scheduled and the time it was picked up by a worker and started.*Shown as millisecond*     |
| **aws.swf.decision\_task\_schedule\_to\_start\_time.maximum**(gauge)   | Maximum time interval, in milliseconds, between the time that the decision task was scheduled and the time it was picked up by a worker and started.*Shown as millisecond* |
| **aws.swf.decision\_task\_schedule\_to\_start\_time.minimum**(gauge)   | Minimum time interval, in milliseconds, between the time that the decision task was scheduled and the time it was picked up by a worker and started.*Shown as millisecond* |
| **aws.swf.decision\_task\_start\_to\_close\_time**(gauge)              | The time interval, in milliseconds, between the time that the decision task was started and the time it was closed.                                                        |
| **aws.swf.decision\_task\_start\_to\_close\_time.maximum**(gauge)      | Maximum time interval, in milliseconds, between the time that the decision task was started and the time it was closed.                                                    |
| **aws.swf.decision\_task\_start\_to\_close\_time.minimum**(gauge)      | Minimum time interval, in milliseconds, between the time that the decision task was started and the time it was closed.                                                    |
| **aws.swf.decision\_tasks\_completed**(count)                          | The count of decision tasks that have been completed.                                                                                                                      |
| **aws.swf.pending\_tasks**(count)                                      | The count of pending tasks in a 1 minute interval for a specific Task List.*Shown as task*                                                                                 |
| **aws.swf.provisioned\_bucket\_size**(count)                           | The count of available requests per second.*Shown as request*                                                                                                              |
| **aws.swf.provisioned\_refill\_rate**(count)                           | The count of requests per second that are allowed into the bucket.*Shown as request*                                                                                       |
| **aws.swf.scheduled\_activity\_tasks\_timed\_out\_on\_close**(count)   | The count of activity tasks that were scheduled but timed out on close.                                                                                                    |
| **aws.swf.scheduled\_activity\_tasks\_timed\_out\_on\_start**(count)   | The count of activity tasks that were scheduled but timed out on start.                                                                                                    |
| **aws.swf.started\_activity\_tasks\_timed\_out\_on\_close**(count)     | The count of activity tasks that were started but timed out on close.                                                                                                      |
| **aws.swf.started\_activity\_tasks\_timed\_out\_on\_heartbeat**(count) | The count of activity tasks that were started but timed out due to a heartbeat timeout.                                                                                    |
| **aws.swf.started\_decision\_tasks\_timed\_out\_on\_close**(count)     | The count of decision tasks that started but timed out on closing.                                                                                                         |
| **aws.swf.throttled\_events**(count)                                   | The count of requests that have been throttled.*Shown as request*                                                                                                          |
| **aws.swf.workflow\_start\_to\_close\_time**(gauge)                    | The time, in milliseconds, between the time the workflow started and the time it closed.*Shown as millisecond*                                                             |
| **aws.swf.workflow\_start\_to\_close\_time.maximum**(gauge)            | Maximum time, in milliseconds, between the time the workflow started and the time it closed.*Shown as millisecond*                                                         |
| **aws.swf.workflow\_start\_to\_close\_time.minimum**(gauge)            | Minimum time, in milliseconds, between the time the workflow started and the time it closed.*Shown as millisecond*                                                         |
| **aws.swf.workflows\_canceled**(count)                                 | The count of workflows that were canceled.                                                                                                                                 |
| **aws.swf.workflows\_completed**(count)                                | The count of workflows that were completed.                                                                                                                                |
| **aws.swf.workflows\_continued\_as\_new**(count)                       | The count of workflows that continued as new.                                                                                                                              |
| **aws.swf.workflows\_failed**(count)                                   | The count of workflows that failed.                                                                                                                                        |
| **aws.swf.workflows\_terminated**(count)                               | The count of workflows that were terminated.                                                                                                                               |
| **aws.swf.workflows\_timed\_out**(count)                               | The count of workflows that timed out, for any reason.                                                                                                                     |

Each of the metrics retrieved from AWS are assigned the same tags that appear in the AWS console, including but not limited to host name, security-groups, and more.

### Events{% #events %}

The Amazon SWF integration does not include any events.

### Service Checks{% #service-checks %}

The Amazon SWF integration does not include any service checks.

## Troubleshooting{% #troubleshooting %}

Need help? Contact [Datadog support](https://docs.datadoghq.com/help/).
