AWS Serverless

Amazon Kinesis Data StreamsserverlessAmazon Kinesis Data Streams is a durable, replayable, horizontally-scaled streaming service that ingests and… AWS Step FunctionsserverlessAWS Step Functions is a serverless orchestration service that coordinates AWS services into durable workflows. AWS LambdaserverlessAWS Lambda is the serverless compute primitive on AWS.

Compute without servers to manage — functions, state machines, and streaming ingestion.

Serverless services let you run code and pipelines without provisioning or patching servers: you pay per request, per state transition or per shard, and AWS handles scaling and availability. The three services in this section are often used together.



‹ AWS

1. Overview

Event-Driven Serverless Pipeline Producersapps, devices, logsKinesis Data Streamsordered shardsLambdaper-batch functionStep Functionsmulti-step workflowTargetsS3, DynamoDBKinesis buffers and orders events, Lambda processes each batch, and Step Functions coordinates longer workflows with retries.

AWS Lambda runs a function in response to an event, such as an HTTP request through API Gateway, an S3 upload, a queue message or a batch of stream records, for up to 15 minutes per invocation. Kinesis Data Streams is a durable, replayable log of records split into shards; consumers read in order per shard and can replay retained data. Step Functions coordinates multiple steps as a state machine with built-in retries, branching, parallelism and waiting, so business logic does not need to manage its own orchestration.

2. When to Use Which

NeedService
Run short code on an eventAWS Lambda
Ingest a high-volume ordered stream with replay and multiple consumersKinesis Data Streams
Coordinate many steps, human approvals or long waitsAWS Step Functions

Serverless is a poor fit for steady high-throughput compute (containers on ECS or EKS are usually cheaper) and for work longer than Lambda's 15-minute limit. Watch cold-start latency for latency-sensitive APIs, and use dead-letter queues or failure destinations so failed events are not lost.

3. Common Pitfalls