I trimmed p95 cold starts on a Node 18 Lambda from about 1.2s to 220 ms by bundling with esbuild, hoisting config, and deferring SDK init; at about 250 concurrent invocations it held steady without provisioned concurrency. What minimal patterns are you using to keep serverless endpoints fast and scalable, and when do you decide to pay for provisioned concurrency versus squeezing the code path further?
@OP Biggest win for me was ‘don’t put it in a VPC unless you absolutely need to’ — moving a Node 18 Lambda off VPC cut cold starts from about 900 ms to about 200 ms; when I can’t avoid it (RDS), I’ll use provisioned concurrency just for the auth endpoint during predictable spikes.
@OP Using AWS_NODEJS_CONNECTION_REUSE_ENABLED=1 + keep-alive cut p95 about 150ms on Node 18; caveat: ALB timeouts — at about 200+ concurrents it held steady.
Bumping memory was the easiest lever: going from 512 to 1024 MB dropped cold start about 40% thanks to “more memory = more CPU,” and cost stayed flat since duration fell… At about 250 concurrents like you, p95 settled around 200–220 ms without provisioned concurrency. I only pay for PC on the truly latency-critical path and use dynamic imports for rare deps to keep init skinny.