Skip to content

CONCEPT Cited by 3 sources

Cold Start

Cold start is the extra latency a serverless / scale-to-zero service incurs when it has to allocate execution capacity for a request whose target has no warm instance — VM boot, runtime init, user-code init.

Why it exists

Cold start is the direct counterpart of scale-to-zero: if an application consumes no idle capacity when unused, the first request after a quiet period has to pay the bring-up cost. See concepts/scale-to-zero.

How Lambda framed it, day one

The 2014 PR/FAQ was explicit about the shape of the latency curve: "Applications in steady use have typical latencies in the range of 20-50ms, determined by timing a simple 'echo' application from a client hosted in Amazon EC2. Latency will be higher the first time an application is deployed and when an application has not been used recently." The team also committed to an internal measurement of "latency of process invocation to execution of customer code" as a dimension to optimise.

(Source: sources/2024-11-15-allthingsdistributed-aws-lambda-prfaq-after-10-years)

10-year evolution of the attack surface

  • Single-tenant EC2 instances (launch) — slow to spin up, expensive to keep warm.
  • Firecracker micro-VMs — startup in milliseconds; enables dense packing so warm capacity is cheap to keep around.
  • Container image support (2020) — up to 10 GB images; solved via on-demand block-level image loading (Marc Brooker, USENIX ATC '23) so pulling a 10 GB image isn't a 10 GB cold start.
  • SnapStart (2022) — pre-initialized Firecracker VM snapshots, restored on demand; "reduced cold start latency — especially for Java functions — by up to 90%."

What "fast cold start" actually means mechanically

The levers are consistent across providers:

  • Smaller / snapshotted isolation units (micro-VMs, not full OS boots).
  • Lazy / on-demand loading of code and dependencies.
  • Aggressive caching of the runtime + user init past the first request.
  • Pre-warmed capacity pools (Lambda Provisioned Concurrency, container always-on minimums) — trades idle cost back for zero cold-start.

Seen in

Last updated · 200 distilled / 1,178 read