workflow_steps
Creates, updates, deletes, gets or lists a workflow_steps resource.
Overview
| Name | workflow_steps |
| Type | Resource |
| Id | aws.migrationhuborchestrator.workflow_steps |
Fields
The following fields are returned by SELECT queries:
- get_workflow_step
- list_workflow_steps
| Name | Datatype | Description |
|---|---|---|
name | string | The name of the step. |
creation_time | string (date-time) | The time at which the step was created. |
description | string | The description of the step. |
end_time | string (date-time) | The time at which the step ended. |
last_start_time | string (date-time) | The time at which the workflow was last started. |
next | array | The next step. |
no_of_srv_completed | integer | The number of servers that have been migrated. |
no_of_srv_failed | integer | The number of servers that have failed to migrate. |
outputs | array | The outputs of the step. |
owner | string | The owner of the step. (AWS_MANAGED, CUSTOM) |
previous | array | The previous step. |
script_output_location | string | The output location of the script. |
status | string | The status of the step. (AWAITING_DEPENDENCIES, SKIPPED, READY, IN_PROGRESS, COMPLETED, FAILED, PAUSED, USER_ATTENTION_REQUIRED) |
status_message | string | The status message of the migration workflow. |
step_action_type | string | The action type of the step. You must run and update the status of a manual step for the workflow to continue after the completion of the step. (MANUAL, AUTOMATED) |
step_group_id | string | The ID of the step group. |
step_id | string | The ID of the step. |
step_target | array | The servers on which a step will be run. |
total_no_of_srv | integer | The total number of servers that have been migrated. |
workflow_id | string | The ID of the migration workflow. |
workflow_step_automation_configuration | object | The custom script to run tests on source or target environments. |
| Name | Datatype | Description |
|---|---|---|
name | string | The name of the step. |
description | string | The description of the step. |
next | array | The next step. |
no_of_srv_completed | integer | The number of servers that have been migrated. |
no_of_srv_failed | integer | The number of servers that have failed to migrate. |
owner | string | The owner of the step. (AWS_MANAGED, CUSTOM) |
previous | array | The previous step. |
script_location | string | The location of the script. |
status | string | The status of the step. (AWAITING_DEPENDENCIES, SKIPPED, READY, IN_PROGRESS, COMPLETED, FAILED, PAUSED, USER_ATTENTION_REQUIRED) |
status_message | string | The status message of the migration workflow. |
step_action_type | string | The action type of the step. You must run and update the status of a manual step for the workflow to continue after the completion of the step. (MANUAL, AUTOMATED) |
step_id | string | The ID of the step. |
total_no_of_srv | integer | The total number of servers that have been migrated. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_workflow_step | select | workflowId, stepGroupId, id, region | Get a step in the migration workflow. | |
list_workflow_steps | select | workflow_id, step_group_id, region | nextToken, maxResults | List the steps in a workflow. |
create_workflow_step | insert | region, name, stepGroupId, workflowId, stepActionType | Create a step in the migration workflow. | |
update_workflow_step | update | id, region, stepGroupId, workflowId | Update a step in a migration workflow. | |
delete_workflow_step | delete | id, stepGroupId, workflowId, region | Delete a step in a migration workflow. Pause the workflow to delete a running step. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the step you want to delete. |
region | string | AWS region (default: us-east-1) |
stepGroupId | string | The ID of the step group that contains the step you want to delete. |
step_group_id | string | The ID of the step group. |
workflowId | string | The ID of the migration workflow. |
workflow_id | string | The ID of the migration workflow. |
maxResults | integer | The maximum number of results that can be returned. |
nextToken | string | The pagination token. |
SELECT examples
- get_workflow_step
- list_workflow_steps
Get a step in the migration workflow.
SELECT
name,
creation_time,
description,
end_time,
last_start_time,
next,
no_of_srv_completed,
no_of_srv_failed,
outputs,
owner,
previous,
script_output_location,
status,
status_message,
step_action_type,
step_group_id,
step_id,
step_target,
total_no_of_srv,
workflow_id,
workflow_step_automation_configuration
FROM aws.migrationhuborchestrator.workflow_steps
WHERE workflowId = '{{ workflowId }}' -- required
AND stepGroupId = '{{ stepGroupId }}' -- required
AND id = '{{ id }}' -- required
AND region = '{{ region }}' -- required
;
List the steps in a workflow.
SELECT
name,
description,
next,
no_of_srv_completed,
no_of_srv_failed,
owner,
previous,
script_location,
status,
status_message,
step_action_type,
step_id,
total_no_of_srv
FROM aws.migrationhuborchestrator.workflow_steps
WHERE workflow_id = '{{ workflow_id }}' -- required
AND step_group_id = '{{ step_group_id }}' -- required
AND region = '{{ region }}' -- required
AND nextToken = '{{ nextToken }}'
AND maxResults = '{{ maxResults }}'
;
INSERT examples
- create_workflow_step
- Manifest
Create a step in the migration workflow.
INSERT INTO aws.migrationhuborchestrator.workflow_steps (
name,
stepGroupId,
workflowId,
stepActionType,
description,
workflowStepAutomationConfiguration,
stepTarget,
outputs,
previous,
next,
region
)
SELECT
'{{ name }}' /* required */,
'{{ stepGroupId }}' /* required */,
'{{ workflowId }}' /* required */,
'{{ stepActionType }}' /* required */,
'{{ description }}',
'{{ workflowStepAutomationConfiguration }}',
'{{ stepTarget }}',
'{{ outputs }}',
'{{ previous }}',
'{{ next }}',
'{{ region }}'
RETURNING
id,
name,
step_group_id,
workflow_id
;
# Description fields are for documentation purposes
- name: workflow_steps
props:
- name: region
value: "{{ region }}"
description: Required parameter for the workflow_steps resource.
- name: name
value: "{{ name }}"
- name: stepGroupId
value: "{{ stepGroupId }}"
- name: workflowId
value: "{{ workflowId }}"
- name: stepActionType
value: "{{ stepActionType }}"
valid_values: ['MANUAL', 'AUTOMATED']
- name: description
value: "{{ description }}"
- name: workflowStepAutomationConfiguration
description: |
The custom script to run tests on source or target environments.
value:
scriptLocationS3Bucket: "{{ scriptLocationS3Bucket }}"
scriptLocationS3Key:
linux: "{{ linux }}"
windows: "{{ windows }}"
command:
linux: "{{ linux }}"
windows: "{{ windows }}"
runEnvironment: "{{ runEnvironment }}"
targetType: "{{ targetType }}"
- name: stepTarget
value:
- "{{ stepTarget }}"
- name: outputs
value:
- name: "{{ name }}"
dataType: "{{ dataType }}"
required_: {{ required_ }}
value:
integerValue: {{ integerValue }}
stringValue: "{{ stringValue }}"
listOfStringValue:
- "{{ listOfStringValue }}"
- name: previous
value:
- "{{ previous }}"
- name: next
value:
- "{{ next }}"
UPDATE examples
- update_workflow_step
Update a step in a migration workflow.
UPDATE aws.migrationhuborchestrator.workflow_steps
SET
stepGroupId = '{{ stepGroupId }}',
workflowId = '{{ workflowId }}',
name = '{{ name }}',
description = '{{ description }}',
stepActionType = '{{ stepActionType }}',
workflowStepAutomationConfiguration = '{{ workflowStepAutomationConfiguration }}',
stepTarget = '{{ stepTarget }}',
outputs = '{{ outputs }}',
previous = '{{ previous }}',
next = '{{ next }}',
status = '{{ status }}'
WHERE
id = '{{ id }}' --required
AND region = '{{ region }}' --required
AND stepGroupId = '{{ stepGroupId }}' --required
AND workflowId = '{{ workflowId }}' --required
RETURNING
id,
name,
step_group_id,
workflow_id;
DELETE examples
- delete_workflow_step
Delete a step in a migration workflow. Pause the workflow to delete a running step.
DELETE FROM aws.migrationhuborchestrator.workflow_steps
WHERE id = '{{ id }}' --required
AND stepGroupId = '{{ stepGroupId }}' --required
AND workflowId = '{{ workflowId }}' --required
AND region = '{{ region }}' --required
;