AWS Lambda: What You Should Know

A field-guide breakdown of AWS Lambda: what serverless functions are, how the execution model works, where they fit, and the tradeoffs teams hit.

Editorial illustration of an event triggering a small Lambda function box with scaling copies on archive paper

Track: Cloud Engineering. Era: the serverless sessions that arrived once “don’t manage servers” stopped sounding like a joke. Modern lesson: Lambda removes a whole class of operational work and hands you a different, subtler set of constraints.

AWS Lambda is a serverless compute service that runs your code in response to events without you provisioning or managing servers. You upload a function, AWS runs it when triggered, scales it automatically, and bills you for the compute time used. As of 2026, confirm current runtime support, limits, and pricing against the official AWS Lambda documentation.

The recovered track

Early cloud talks were about renting virtual machines. Then a different session type appeared: speakers who argued the unit of deployment should be a function, not a server. The reaction in the room was split, relief from people tired of patching instances, skepticism from people who’d been burned by magic that hid too much.

Both reactions were correct. Serverless genuinely removed the toil of running servers. It also moved complexity somewhere less visible: cold starts, event wiring, and execution limits. The conference framing that aged best wasn’t “serverless is the future.” It was “serverless changes what you’re responsible for.” That’s still the right lens.

What is AWS Lambda, really?

Lambda is event-driven compute. You define a function, attach it to a trigger, and AWS handles everything between the event and the result. The AWS Lambda documentation describes the core model: an event source invokes your function, Lambda provisions an execution environment, runs your code, and tears the environment down (or reuses it for a while) afterward.

The defining traits:

This is the far end of the shared responsibility model: with Lambda, AWS owns far more of the stack than it does with raw virtual machines, and your responsibility narrows toward your code, your event wiring, and your permissions. We cover that boundary in our AWS cloud overview.

How does the execution model work?

Understanding one concept, the execution environment lifecycle, explains most of Lambda’s quirks.

When an event arrives and no environment is warm, Lambda creates one: it downloads your code, starts the runtime, and runs any initialization. That setup time is the cold start. Once warm, the environment can be reused for subsequent invocations, skipping the setup, a warm start. Environments are eventually recycled when idle.

PhaseWhat happensCost to you
Cold startNew environment created and initializedAdded latency on first hit
Warm invocationExisting environment reusedMinimal overhead
Concurrent loadMultiple environments run in parallelScales automatically, within limits

This lifecycle is why Lambda functions should initialize expensive resources (database connections, SDK clients) outside the handler, where they survive across warm invocations. It’s also why latency-sensitive, steady-traffic workloads sometimes fit a long-running service better than a function that keeps going cold.

Where does Lambda fit, and where doesn’t it?

Naming the tradeoff matters more than declaring a winner.

Lambda fits well when:

Lambda fits poorly when:

A practical decision rule: reach for Lambda when the work is genuinely event-driven and bursty, and reach for a container or instance when the work is continuous. Don’t choose serverless because it’s fashionable, choose it because the workload’s shape matches the billing and execution model. The same delivery discipline from our CI/CD pipeline field guide applies: functions still need tests, versioning, and observable deploys.

How do Lambda functions get triggered?

The event source is half of any Lambda design, and understanding the trigger types clarifies where the service shines. A function does nothing on its own, it waits for something to invoke it.

The common trigger patterns:

The trigger type changes how you reason about errors and retries. A synchronous API call surfaces failures to the user immediately; an asynchronous event retries silently; a stream invocation can block on a poison-pill record if you don’t handle failures explicitly. Choosing the trigger is choosing the failure model, and that’s a design decision worth making deliberately rather than inheriting by accident.

What does Lambda cost, and where does it surprise teams?

Lambda’s pricing is genuinely simple at the core and genuinely surprising at the edges. You’re billed on two axes: the number of invocations and the compute time they consume, where compute time is a function of both duration and the memory you allocate.

That last point trips people up. Allocating more memory to a function also gives it more CPU, so a memory bump can make a function finish faster, sometimes fast enough that the higher per-millisecond rate is offset by the shorter run. Tuning memory is a real optimization lever, not just a capacity setting.

The honest surprises come from the surrounding services. A Lambda function that calls a database, sends events to a queue, and logs heavily incurs costs across all of those, and for high-volume steady traffic the total can exceed what an always-on container would cost. The “pay nothing when idle” benefit is real and valuable for spiky workloads; it inverts into a disadvantage when traffic is constant and heavy. A practical habit: model the cost at your expected request volume before committing, not after the first surprising invoice.

What changed, and what didn’t

Lambda’s edges have softened over the years, longer timeouts, more memory, container image packaging, and provisioned concurrency to blunt cold starts. The hard limits that made early adopters cautious have moved, so re-check current numbers rather than trusting older write-ups.

What didn’t change is the core bargain those first serverless talks described. Lambda trades operational control for operational convenience. You stop managing servers and start managing events, limits, and cold-start behavior. For the right workload, that trade is excellent. The skill is knowing which workload that is.

Sources