Using lambda-chaos-extension
to inject faults to Lambda functions without any modification to function code.
This demo inject two faults:
- Add 5 minutes delay to 10% of function invokes, causing the function to timeout.
- Replace function response for 50% of invokes.
To build and deploy your application for the first time, run the following in your shell:
sam build --use-container
sam deploy --guided
Browse the API Gateway URL or curl it from command line for couple of times.
- The normal results are status 200, {"message": "hello world"}.
- 50% of the responses are status 500, {"message": "hello, Chaos!!!"}
- 10% of the responses are status 502, {"message": "Internal server error"}.
See CONTRIBUTING for more information.
This library is licensed under the MIT-0 License. See the LICENSE file.