Test harness for AWS Lambda
Project description
Sets up and executes Python code in a method highly analogous to the Lambda runtime environment.
Current notable gaps include:
No support for runtime or memory limits
No support for intra-execution cgroup freeze/thaw
Other than these caveats, it should look and feel roughly like a real Lambda execution, including all the correct environment variables, data structures, and log messages.
Check out the page on GitHub for complete documentation.
Example
[user@host ~]$ lambda invoke --path ~/lambdas/Exec_Command_Example/ --payload '{"command": "echo Hello, World"}' <CREATE Id:4771091906264488b7ad71f930e2aea0> <RUN Mode:event Handler:function.lambda_handler Suppress_init:0> <RUNNING> [INFO] 2016-12-07T08:54:13.632Z Function module init() called START RequestId: b64c27dc-0fe6-4ba7-9123-24ea0cc3072f Version: $LATEST [INFO] 2016-12-07T08:54:13.633Z b64c27dc-0fe6-4ba7-9123-24ea0cc3072f Running command: echo Hello, World END: RequestId: b64c27dc-0fe6-4ba7-9123-24ea0cc3072f REPORT: RequestId: b64c27dc-0fe6-4ba7-9123-24ea0cc3072f Duration: 92.31 ms Billed Duration: 100 ms Memory Size: 128 MB Max Memory Used: N/A MB Hello, World <TERMINATE Id:4771091906264488b7ad71f930e2aea0>
Usage
Bootstrap once, then invoke:
lambda bootstrap lambda invoke --path /path/to/lambda/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for lambda_harness-1.3.0-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c57c8aeab23e8b4ef7c4489b7419a26579af8052b653e8c75ccaaacfd4898afc |
|
MD5 | 8488b1bb7350b31423609760fe9f83ad |
|
BLAKE2b-256 | 39a5673703fd5491d23232e8ff88e12b450ca2cce6beac630bc87c3bda10a10b |