Containers vs Serverless
Architectural tradeoffs between containerized services and function-as-a-service platforms.
Overview
What is being compared
Containers package an application and its dependencies into a portable image that runs the same way in every environment. Serverless hides the infrastructure entirely: you deploy individual functions that events trigger. The choice affects cost, latency, operational burden and how finely you deploy.
- What you ship — A portable image with the app and its dependencies — Individual functions
- How it runs — Consistently across environments — Triggered by events
- Infrastructure — Yours to run — Abstracted away entirely
- Deployment granularity — Whole application — One function at a time
- Fits — Complex apps, stateful services, predictable traffic, custom runtimes or binaries — Event-driven workflows, low-traffic APIs, scheduled tasks, glue code
Sign up free to read the full topic
More Comparisons topics
Start free on Cariara · Coding problems · System design studio