Skip to content

Commit 7f4ad28

Browse files
authored
docs: Improve the docs of the aws-*-sqs-worker examples (#631)
1 parent 8bf8103 commit 7f4ad28

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

aws-node-sqs-worker/README.md

+9-2
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,18 @@ authorAvatar: 'https://avatars1.githubusercontent.com/u/13742415?s=200&v=4'
1212

1313
# Serverless Framework Node SQS Producer-Consumer on AWS
1414

15-
This template demonstrates how to develop and deploy a simple SQS-based producer-consumer service running on AWS Lambda using the traditional Serverless Framework and [Lift](https://github.com/getlift/lift) plugin. It allows to accept messages, for which computation might be time or resource intensive, and offload their processing to an asynchronous background process for a faster and more resilient system.
15+
This template demonstrates how to develop and deploy a simple SQS-based producer-consumer service running on AWS Lambda using the Serverless Framework and the [Lift](https://github.com/getlift/lift) plugin. It allows to accept messages, for which computation might be time or resource intensive, and offload their processing to an asynchronous background process for a faster and more resilient system.
1616

1717
## Anatomy of the template
1818

19-
This template defines one function `producer` and one Lift construct - `jobs`. Producer function is triggered by `http` event type, accepts JSON payload and sends it to a corresponding SQS queue for further processing. To learn more about `http` event configuration options, please refer to [http event docs](https://www.serverless.com/framework/docs/providers/aws/events/apigateway/). Jobs construct is responsible for two things. It creates SQS queue along with corresponding "dead-letter queue" and defines `worker` function that is responsible for processing events from created SQS queue. For more details about `queue` construct type and Lift plugin in general, please refer to [docs](https://github.com/getlift/lift/blob/master/docs/queue.md). For more details about SQS processing with AWS Lambda, please refer to official [AWS documentation](https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html).
19+
This template defines one function `producer` and one Lift construct - `jobs`. The producer function is triggered by `http` event type, accepts JSON payloads and sends it to a SQS queue for asynchronous processing. The SQS queue is created by the `jobs` queue construct of the Lift plugin. The queue is set up with a "dead-letter queue" (to receive failed messages) and a `worker` Lambda function that processes the SQS messages.
20+
21+
To learn more:
22+
23+
- about `http` event configuration options, refer to [http event docs](https://www.serverless.com/framework/docs/providers/aws/events/apigateway/)
24+
- about the `queue` construct, refer to [the `queue` documentation in Lift](https://github.com/getlift/lift/blob/master/docs/queue.md)
25+
- about the Lift plugin in general, refer to [the Lift project](https://github.com/getlift/lift)
26+
- about SQS processing with AWS Lambda, please refer to the official [AWS documentation](https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html)
2027

2128
### Deployment
2229

aws-python-sqs-worker/README.md

+8-3
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,18 @@ authorAvatar: 'https://avatars1.githubusercontent.com/u/13742415?s=200&v=4'
1212

1313
# Serverless Framework Python SQS Producer-Consumer on AWS
1414

15-
This template demonstrates how to develop and deploy a simple SQS-based producer-consumer service running on AWS Lambda using the traditional Serverless Framework and [Lift](https://github.com/getlift/lift) plugin. It allows to accept messages, for which computation might be time or resource intensive, and offload their processing to an asynchronous background process for a faster and more resilient system.
15+
This template demonstrates how to develop and deploy a simple SQS-based producer-consumer service running on AWS Lambda using the Serverless Framework and the [Lift](https://github.com/getlift/lift) plugin. It allows to accept messages, for which computation might be time or resource intensive, and offload their processing to an asynchronous background process for a faster and more resilient system.
1616

1717
## Anatomy of the template
1818

19-
This template defines one function `producer` and one Lift construct - `jobs`. Producer function is triggered by `http` event type, accepts JSON payload and sends it to a corresponding SQS queue for further processing. To learn more about `http` event configuration options, please refer to [http event docs](https://www.serverless.com/framework/docs/providers/aws/events/apigateway/). Jobs construct is responsible for two things. It creates SQS queue along with corresponding "dead-letter queue" and defines `worker` function that is responsible for processing events from created SQS queue. For more details about `queue` construct type and Lift plugin in general, please refer to [docs](https://github.com/getlift/lift/blob/master/docs/queue.md). For more details about SQS processing with AWS Lambda, please refer to official [AWS documentation](https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html).
19+
This template defines one function `producer` and one Lift construct - `jobs`. The producer function is triggered by `http` event type, accepts JSON payloads and sends it to a SQS queue for asynchronous processing. The SQS queue is created by the `jobs` queue construct of the Lift plugin. The queue is set up with a "dead-letter queue" (to receive failed messages) and a `worker` Lambda function that processes the SQS messages.
2020

21-
## Usage
21+
To learn more:
22+
23+
- about `http` event configuration options, refer to [http event docs](https://www.serverless.com/framework/docs/providers/aws/events/apigateway/)
24+
- about the `queue` construct, refer to [the `queue` documentation in Lift](https://github.com/getlift/lift/blob/master/docs/queue.md)
25+
- about the Lift plugin in general, refer to [the Lift project](https://github.com/getlift/lift)
26+
- about SQS processing with AWS Lambda, please refer to the official [AWS documentation](https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html)
2227

2328
### Deployment
2429

0 commit comments

Comments
 (0)