| Crates.io | cold-stat |
| lib.rs | cold-stat |
| version | 0.1.3 |
| created_at | 2024-03-21 10:50:08.211218+00 |
| updated_at | 2024-03-28 09:48:32.307015+00 |
| description | CLI to statically analyze cold start of AWS Lambda functions. |
| homepage | https://github.com/exoego/cold-stat |
| repository | https://github.com/exoego/cold-stat |
| max_upload_size | |
| id | 1181481 |
| size | 95,201 |
A CLI tool to statically analyze the initialization time, known as cold-start, of AWS Lambda functions.
lambda:GetFunctionConfiguration to fetch the current env vars of the functionLambda.UpdateFunctionConfiguration to update the env vars of the function, to force cold-startlambda:InvokeFunction to invoke tha functionlogs:StartQuery to query CloudWatch Logs for cold start analysiscargo install cold-stat
cold-stat [OPTIONS] --function <FUNCTION> --payload <PAYLOAD>
# Example
cold-stat --verbose --function=YOUR-FUNC-NAME --iterations=300 \
--payload='{"foo": "bar"}'
-f, --function <FUNCTION>
-p, --payload <PAYLOAD>
--log-group-name <LOG_GROUP_NAME>
/aws/lambda/FUNCTION]--log-stream-filter <LOG_STREAM_FILTER>
/YOUR-FUNCTION-NAME/] when log streams are named like 2021/01/01/YOUR-FUNCTION-NAME[$LATEST]-i, --iterations <ITERATIONS>
30 at least. Because the number of collected cold starts often is a bit shorter than the specified ITERATIONS due to eventual consistency of CloudWatch Logs100]-v, --verbose
-h, --help
-V, --version
mem
count
stddev, min, max
p50, p90, p95, p99, p995, p999
p50 is 50 percentile, also known as the medianp995 and p999 are 99.5 and 99.9 percentiles, respectivelygit clone https://github.com/exoego/cold-stat
cd cold-stat
cargo build
cargo run -- \
--function=YOUR-FUNC-NAME \
--iterations=10 \
--verbose \
--payload='{"foo": "bar"}'