I've created AWS SWF workers\Decider using "Node.js" and I can run on my machine, Could you please advise about best practice to deploy and run SWF\Worker\Decider on the Amazon background.
2 Answers
There's two basic ways to use Amazon Simple Workflow:
- Workers 'call in' to SWF requesting work, or
- SWF can trigger AWS Lambda functions when there is work to perform
Given your description, the latter method would probably be best for you.
From AWS Lambda Tasks:
There are a number of benefits of using Lambda tasks in place of a traditional Amazon SWF activity:
- Lambda tasks don’t need to be registered or versioned like Amazon SWF activity types.
- You can use any existing Lambda functions that you've already defined in your workflows.
- Lambda functions are called directly by Amazon SWF; there is no need for you to implement a worker program to execute them as you must do with traditional activities. Lambda provides you with metrics and logs for tracking and analyzing your function executions.
Alternatively, you could consider using AWS Step Functions, which is a newer service than SWF. It co-ordinates the execution of AWS Lambda functions as a state machine, which might be more appropriate to your task.

- 241,921
- 22
- 380
- 470
-
Thank you, I've created step functions instead SWF, and it's fit to my business needs. – Laith Maali Jul 30 '17 at 14:16
I'm not sure whether this is the best options. But I have been using SWF quite some time now, and I am running my nodejs deciders and workers in Aws Elastic Container Service (ECS).
Workers you can run via lambda functions also, but deciders anyways you need to run separately since currently you can't run deciders via lambda functions.

- 429
- 3
- 10