AWS Database Migration Service ExecModule
Overview
AwsDmsModule reads replication task state and statistics from AWS Database Migration Service (AWS DMS). Use it to watch a known migration task, spot stalled or failed tasks in a region, or gather progress for a migration handoff. Each run reads one page from one AWS region. It can limit the lookup to one exact task ARN.
The module returns task summaries and keeps the AWS-side configuration and migration controls outside the workflow. AWS DMS continues to run the replication.
Usage
- Create and verify an AWS Database Migration Service connection in the Integration Account Console. Confirm its status is
READY. - Add AWS Database Migration Service in Workflow Studio and select the saved account under General > Connection.
- Set the AWS region. Pass
taskArnwhen you already know which task to watch, or omit it to read a regional page. - Check the top-level
statusfor the lookup outcome. On success, evaluate the task's ownstatusand available statistics.
Inputs
| Input | Type | Required | Default | Purpose |
|---|---|---|---|---|
operation | string | No | describe_replication_tasks | Read a page of replication task summaries. |
region | string | Yes | — | AWS DMS region in the commercial or GovCloud partition. |
taskArn | string | No | — | Exact DMS replication task ARN with a task: resource. The ARN region and partition must match region. |
limit | integer | No | 25 | Maximum tasks per page, from 20 through 100. |
marker | string | No | — | Opaque continuation marker returned by the preceding page. |
Outputs
| Output | Meaning |
|---|---|
status / operation | Lookup outcome (success or error) and the selected operation. |
items / count | Task summaries in provider order and the number returned on this page. |
hasMore / marker | Whether another page is available and the marker to request it. |
requestId | AWS request reference when available. |
error | Error code, redacted message, retryability, and HTTP status when available. |
Each summary can include taskArn, taskId, status, migrationType, and a stats object. The statistics map the available full-load progress to progressPercent and task elapsed time to elapsedMilliseconds. AWS can also return tablesLoaded, tablesLoading, tablesQueued, and tablesErrored. Treat a missing statistic as unknown. Full-load progress does not establish that ongoing change data capture has caught up. AWS replication task statistics
IntegrationAccount Requirements
Use the AWS Database Migration Service template with account name AWS. Store the access key ID in the protected API key field and the secret access key in the protected password field. Verify the connection before selecting it in the workflow. ValkyrAI resolves these protected values at runtime to sign the request.
Grant the AWS principal only dms:DescribeReplicationTasks for this operation. The IAM action requires Resource: "*" because AWS does not list a resource type for it. The optional task ARN narrows the API query. The IAM principal determines which account the workflow can inspect. AWS DMS IAM actions and resource types
Configuration
The module connects over HTTPS to the standard AWS DMS endpoint in the selected region. Choose a region that serves DMS and a saved connection authorized in that AWS account. This connection accepts an access key pair. Session tokens, inline credentials, and custom endpoints are outside its contract.
Operations
describe_replication_tasks calls AWS DMS with WithoutSettings enabled. If you supply taskArn, it applies the replication-task-arn filter. An empty page is a valid response. The module returns only the summary fields listed above. Endpoints, table mappings, task settings, and provider failure text are excluded. AWS DescribeReplicationTasks reference
Errors and Failure Modes
VALIDATION_ERRORindicates an invalid region, task ARN, operation, or page input.INTEGRATION_ACCOUNT_ERRORindicates an unusable connection. Check that the account is verified and its protected fields are configured.- An
AWS_DMS_HTTP_error includes the HTTP status in the code. For authorization or request errors, check the region, IAM permissions, and task ARN. Retain the AWSrequestIdfor investigation when available. - Use
error.retryableto decide whether to schedule another lookup. Apply bounded backoff to avoid repeated requests during throttling or a service outage. - A successful lookup can still report a failed replication task. Route a failed task to migration triage. Handle lookup errors separately and keep the last known state.
Example
During a migration, monitor the replication task for an orders database. Supply its ARN from an earlier workflow step so that concurrent migrations do not affect the result.
{
"operation": "describe_replication_tasks",
"region": "us-west-2",
"taskArn": "arn:aws:dms:us-west-2:123456789012:task:AAABBBCCC0123456789YYYZZZ0"
}
A lookup during the full load can return this summary.
{
"status": "success",
"operation": "describe_replication_tasks",
"items": [
{
"taskArn": "arn:aws:dms:us-west-2:123456789012:task:AAABBBCCC0123456789YYYZZZ0",
"taskId": "orders-migration",
"status": "running",
"migrationType": "full-load-and-cdc",
"stats": {
"progressPercent": 75,
"elapsedMilliseconds": 240000,
"tablesLoaded": 15,
"tablesLoading": 2,
"tablesQueued": 3,
"tablesErrored": 0
}
}
],
"count": 1,
"hasMore": false
}
Record the progress and schedule another lookup. Send failed tasks or nonzero error counts to an operator for review. Before a cutover, independently verify the target data and any ongoing replication lag your migration plan requires.
Notes
- When
hasMoreis true, passmarkerunchanged with the same connection, region, task filter, and page size. Bound the number of pages and keep markers out of alerts. - Space polls that share an AWS account and region. See the AWS DMS endpoints and quotas.
- The read is safe to repeat. AWS can report different state or counters as the migration progresses. Deduplicate downstream alerts by task ARN and the condition that triggered the alert.
- The module does not create, start, stop, modify, or delete tasks. It does not read source or target database rows or measure replication lag.