Skip to content

An AWS Lambda function which serves as HTTP gateway relay messages to an SQS queue in order to trigger the worker.

License

Notifications You must be signed in to change notification settings

NovelService/NovelLambdaPost

Repository files navigation

NovelLambdaPost

An AWS Lambda function which serves as HTTP gateway relay messages to an SQS queue in order to trigger the worker.

Configuration

Runtime settings

Runtime=Java 11 (Corretto)
Handler=com.xiangronglin.novel.lambda.post.AwsHandler::handleRequest
Architecture=x86_64

Environment Variables

Set these values as environment variables for the lambda function.

SQS_QUEUE_URL=<your-sqs-url>
DYNAMO_DB_TABLE_NAME=<your-table-name>
REGION=<your-region>
JAVA_TOOL_OPTIONS=-XX:+TieredCompilation -XX:TieredStopAtLevel=1

Role

The lambda needs a role with permission:

  • "sqs:SendMessage"
  • "dynamodb:PutItem"

And optionally for logging

  • Policy "AWSLambdaBasicExecutionRole"

About

An AWS Lambda function which serves as HTTP gateway relay messages to an SQS queue in order to trigger the worker.

Topics

Resources

License

Stars

Watchers

Forks

Languages