Lambda Timeout & Throttle Pressure
CostLens flags Lambda functions with a high share of throttled or timed-out invocations — capped runs still bill toward the configured timeout.
A timed-out Lambda invocation is billed for its full configured timeout regardless of how much useful work it did, and throttling forces retries that bill again. CostLens flags functions under timeout/throttle pressure so you can raise concurrency limits or right-size the timeout and remove the wasted spend.
How it works
CostLens lists all Lambda functions
Calls lambda:ListFunctions in each configured region.
Reads throttle and invocation metrics
Queries CloudWatch Throttles and Invocations over the past 14 days.
Flags high pressure
Flags functions where more than 2% of invocations are throttled (or timing out), with enough monthly traffic to matter.
Estimates wasted spend
Estimates the compute billed to capped/retried invocations. Severity scales with the estimated monthly waste.
What to do
- Open the recommendation and review the throttle rate and configured timeout.
- For throttling: raise the function's reserved/provisioned concurrency, or smooth the upstream trigger rate.
- For timeouts: right-size the timeout, or optimise the slow path. This check is advisory — there is no automated fix.
- Re-run analysis; the finding clears once pressure drops below the threshold.
Severity levels
| Severity | Estimated monthly savings |
|---|---|
| critical | >$500 |
| high | $100–$500 |
| medium | $20–$100 |
| low | <$20 |
Required IAM permissions
Read-only — covered by the CostLens ReadOnlyAccess policy from AWS Accounts:
lambda:ListFunctions
cloudwatch:GetMetricStatistics
Limitations
- Advisory only — CostLens does not change concurrency or timeout settings.
- Low-traffic functions are skipped to avoid noise from small samples.