You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: event-driven-workflow-monitor/README.md
+3-3
Original file line number
Diff line number
Diff line change
@@ -32,18 +32,18 @@ Important: this application uses various AWS services and there are costs associ
32
32
33
33
## How it works
34
34
35
-
This example implements a so called workflow monitor task which succeeds or fails depending on events send to a custom [Amazon EventBridge](https://aws.amazon.com/eventbridge/) event bus. The infrastructure code deploys the follown sample state machine.
35
+
This example implements a so called workflow monitor task which succeeds or fails depending on events send to a custom [Amazon EventBridge](https://aws.amazon.com/eventbridge/) event bus. The infrastructure code deploys the following sample state machine.
36
36
37
37

38
38
39
39
At the start of a workflow execution, a workflow monitor task is started and runs in parallel to other tasks. This workflow monitor task waits for callbacks triggered by events sent to Amazon EventBridge. For example, an error occuring somewhere in the system - outside of the workflow - might emit an error event and trigger the failure of the workflow monitor task.
40
40
41
41
Events are associated with workflows using a unique identifier. In this example we use the term ```workflowkey``` to refer to such an unique identifier. For example, if your event-driven architecture is processing orders, an *Order ID* might be used as ```workflowkey```. Step Functions workflows might handle one part of the order processing while independent services within the event-driven architecture handle other parts of the order processing. In such scenarios the *Order ID* can be the globally unique identifier and it can be used to associate events with workflows.
42
42
43
-
The code of this example deploys a Step Functions workflow, a DynamoDB table, an EventBridge event bus & rules, and Lambda functions. The ```workflowkey```, which is required to associate events with workflows, is stored in a DynamoDB table by the monitor task at the beginning of a workflow execution. Lambda functions react to EventBridge events and send task success or failure commands to the workflow monitor task. We use a wait task in our sample workflow. You can replace this workflow with arbitrary workflow tasks. Just note that the ```StopWorkflowMonitoring``` task requires the ```workflowkey``` as input.
43
+
The code of this example deploys a Step Functions workflow, a DynamoDB table, an EventBridge event bus & rules, and Lambda functions. The ```workflowkey```, which is required to associate events with workflows, is stored in a DynamoDB table by the monitor task at the beginning of a workflow execution. Lambda functions react to EventBridge events and send task success or failure commands to the workflow monitor task. We use a wait task in our sample workflow. You can replace this task with arbitrary Step Functions tasks. Just note that the ```StopWorkflowMonitoring``` task requires the ```workflowkey``` as input.
44
44
45
45
We distinguish between two scenarios in this example:
46
-
* **Graceful completion of the workflow monitor task** just before the workflow execution completes. The completion of the workflow monitor task is triggerd from within the workflow itself by a [PutEvent](https://docs.aws.amazon.com/step-functions/latest/dg/connect-eventbridge.html) task.
46
+
* **Graceful completion of the workflow monitor task** just before the workflow execution completes. The completion of the workflow monitor task is triggered from within the workflow itself by a [PutEvent](https://docs.aws.amazon.com/step-functions/latest/dg/connect-eventbridge.html) task.
47
47
* **Failure of the workflow monitor task** triggered by an external event. In our example, we fail the entire workflow in case of a failing monitor task. But you can [implement arbitrary application logic within the workflow to handle failing monitor tasks](https://docs.aws.amazon.com/step-functions/latest/dg/concepts-error-handling.html).
48
48
49
49
If you are interested in further details about the integration of event-driven architectures with workflows, [this research paper](https://doi.org/10.1016/j.is.2014.04.002) provides furhter information.
Copy file name to clipboardExpand all lines: event-driven-workflow-monitor/example-workflow.json
+2-2
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@
7
7
"type": "Standard",
8
8
"diagram":"/resources/statemachine.png",
9
9
"videoId": "",
10
-
"level": "100",
10
+
"level": "300",
11
11
"framework": "CDK",
12
12
"services": ["events","dynamodb","lambda"],
13
13
"introBox": {
@@ -60,7 +60,7 @@
60
60
"authors": [
61
61
{
62
62
"name": "Stefan Appel",
63
-
"image": "link-to-your-photo.jpg",
63
+
"image": "https://github.com/StefanAppel.png",
64
64
"bio": "Stefan is a Senior Solutions Architect at AWS. He supports global companies adopt cloud technologies. Prior to joining AWS, Stefan drove cloud topics in software architecture, product management, and IT operations departments. He began his career in research on event-based systems. In his spare time, he enjoys hiking and has walked the length of New Zealand following Te Araroa.",
0 commit comments