This example walks through the deployment of a simple workflow, and the steps to set it up.
Use the following command to create the activities parameter in parameter store
aws ssm put-parameter --name /snd/orchestrator/stacks/simpleworkflow/activities --value "['Step1', 'Step2', 'Step3']"
Deploy the Orchestrator Framework
Run the following from the root of this repository
npm run build
npm run activities -- --ssm-key /snd/orchestrator/stacks/simpleorch/activities
npm run deploy -- --stack-name simple-orch-snd --s3-bucket <Existing Deployment Bucket> --s3-prefix sam/snd/simple-orch --parameter-overrides StackTagName=simple-orch EnvironmentTagName=snd
stackery deploy --stack-name simple-orch --env-name snd --strategy local
This step will deploy out a three step workflow leveraging the SAM framework
To deploy the workflow, navigate to the workflow directory and deploy.
cd ./workflow
npm i
sam build
sam deploy --stack-name simple-workflow-snd --s3-bucket <Existing Deployment Bucket> --s3-prefix sam/snd/simple-workflow --parameter-overrides orchstratorStack=simple-orch-snd
This step will deploy the most common type of plugin to the orchestrator activity for Step1.
To deploy the plugin, navigate to the plugin-typical directory and deploy
cd ./plugin-typical
npm i
sam build
sam deploy --stack-name simple-plugin-typical-snd --s3-bucket <Existing Deployment Bucket> --s3-prefix sam/snd/simple-plugin-typical --parameter-overrides orchstratorStack=simple-orch-snd OrchestratorConfig=/snd/orchestrator/stacks/simpleorch/config OrchestratorLayerArn=<The layer arn in the simple-orch output>
This step will deploy a pre and post activity plugin to the orchestrator activity for Step1.
To deploy the plugin, navigate to the plugin-pre-post directory and deploy
cd ./plugin-pre-post
npm i
sam build
sam deploy --stack-name simple-plugin-pre-post-snd --s3-bucket <Existing Deployment Bucket> --s3-prefix sam/snd/simple-plugin-typical --parameter-overrides orchstratorStack=simple-orch-snd OrchestratorConfig=/snd/orchestrator/stacks/simpleorch/config OrchestratorLayerArn=<The layer arn in the simple-orch output>
- Log into your aws account and navigate to "Step Functions".
- Once there find the "simple-step-workflows-dev-workflow" and click on it.
- Click the "Start execution" button
- Past the following into the Input
{
"uid": "123-456"
}
- Click "Start execution"
- Through the AWS Console, navigate to "DynamoDB"
- Under the tables, find "orchestrator-dev-status"
- Click the "Items" tab and select the row shown.
This object which you will have on the screen will show the activities the workflow executed, along with the states of each of the activities.