Alex Rivera

Alex Rivera

Senior PM, Infrastructure at Vercel

Product Case

Edge Functions Cold Start Optimization

Context

Vercel Edge Functions had cold start times averaging 340ms, making them unsuitable for latency-sensitive applications. Competitors were achieving sub-100ms.

Approach

Worked with infrastructure team to implement isolate pooling and snapshot-based initialization. User code is pre-compiled and cached at deploy time. Warm isolates are kept in a pool sized based on traffic patterns.

Key Decisions

Chose to invest in predictive warming based on traffic patterns rather than just reactive pooling. This required building a traffic prediction model. Also decided to support a subset of Node.js APIs to keep runtime lightweight.

Outcome

P50 cold start reduced from 340ms to 47ms. P99 reduced from 890ms to 124ms. Edge Functions adoption increased 3x in following quarter.

Key Metrics

P50: 340ms → 47ms, P99: 890ms → 124ms, 3x adoption increase

Tradeoffs

Limited Node.js API support frustrated some users. We created a compatibility layer for most common APIs but some advanced use cases still require serverless functions.