What reserved and provisioned concurrency each do, how they share the 1,000 concurrent execution account limit, why a low reservation throttles an SQS consumer, and how to cap a worker without starving other functions.

Lambda scales by running more copies of your function at once, up to a limit shared by every function in the account and Region. Reserved concurrency and provisioned concurrency both adjust that scaling, and they are easy to mix up because both are set per function and both involve a number of concurrent executions.
They solve opposite problems: one sets a ceiling and a guarantee, the other buys warm environments.
By default, AWS provides 1,000 concurrent executions per Region across all functions, and you can request an increase. A reservation carves a slice out of that pool: it guarantees the function can always reach that number, and no other function can use it. You can reserve up to the unreserved account concurrency minus 100, because AWS holds 100 units for functions that have no reservation.
New concurrency also arrives at a limited pace, since each function can scale by at most 1,000 execution environments every 10 seconds, per the Lambda concurrency docs, so a sudden spike beyond that is throttled even when the account limit is not reached.
In Terraform, the same setting is an attribute of the function:
resource "aws_lambda_function" "invoice_worker" {
function_name = "invoice-worker"
# ...role, handler and package settings...
reserved_concurrent_executions = 20
}
A reservation of 20 means the function never runs more than 20 copies at once, whatever the traffic, and the remaining account concurrency is reduced by 20 for everything else.
Lambda's SQS poller scales up with queue depth and can invoke the function faster than a small reservation allows. The extra invocations are throttled, the messages return to the queue after the visibility timeout, and each retry counts toward the queue's maxReceiveCount. Enough throttles can send healthy messages to the dead-letter queue.
The better place to cap the consumer is the SQS event source mapping, which has its own maximum concurrency setting that limits how many invocations the poller starts, so the queue waits instead of Lambda throttling. Keep the function's reservation at or above that number. See SQS visibility timeout and SQS dead-letter queues for the retry side.
Use provisioned concurrency when a latency-sensitive function suffers from cold starts, such as an API behind a user-facing page. It keeps a set number of environments ready, and traffic above that number spills into on-demand concurrency with the usual cold starts. When a function also has reserved concurrency, the provisioned amount comes out of that reservation and cannot exceed it. See Lambda provisioned concurrency and Lambda vs Fargate for when it pays off.
Encore is a backend framework with built-in infrastructure, and a consumer's concurrency is a setting on its Pub/Sub subscription in code. The maxConcurrency option, as the subscription source documents it, is the maximum number of messages one instance of the service processes at once for that subscription, so ten instances with a limit of 5 can process 50 messages together. On GCP, Cloud Run services on an unordered topic get push delivery with adaptive concurrency instead. Within that limit, a worker that calls a rate-limited API or a small database stays within what that dependency can take. Failed messages follow the subscription's retry policy and then land in a dead-letter queue.

Run in your terminal to get started locally.
// invoices/invoices.ts
import { Topic, Subscription } from "encore.dev/pubsub";
interface InvoiceRequested {
invoiceId: string;
}
export const requested = new Topic<InvoiceRequested>("invoice-requested", {
deliveryGuarantee: "at-least-once",
});
const _ = new Subscription(requested, "render-invoice", {
// At most 5 messages at a time per service instance, so the PDF renderer
// and the database are never flooded by a burst of messages.
maxConcurrency: 5,
retryPolicy: { minBackoff: "5s", maxBackoff: "2m", maxRetries: 5 },
handler: async (msg) => {
await renderAndStore(msg.invoiceId); // safe to repeat for the same invoice
},
});
async function renderAndStore(invoiceId: string): Promise<void> {
// Render the PDF and write it to object storage keyed by invoice ID.
}
The limit applies per instance, so with several instances the total is higher, and the Pub/Sub docs describe retries and the dead-letter queue. On AWS the topic runs on SNS and SQS in your account as the AWS infrastructure docs describe, and a coding agent that adds a consumer sets its concurrency in the same file and runs it locally with encore run, as the testing docs describe.
Best fit: Teams whose workers must stay within what a database or a third-party API can handle, and who want that limit in the code that defines the worker.
Reserved concurrency sets aside part of your account's concurrency for one function and also caps it at that number. Provisioned concurrency keeps a number of execution environments initialized and ready, to avoid cold starts, and is billed while it is configured.
By default an AWS account gets 1,000 concurrent executions per Region, shared by all functions. You can request an increase. You can reserve up to the unreserved account concurrency minus 100, because AWS keeps 100 units for functions without a reservation.
Lambda throttles new invocations. Synchronous callers receive a 429 TooManyRequestsException, and asynchronous events and queue messages are retried. A reserved concurrency of 0 throttles every invocation, which is a quick way to stop a function.
With Encore, set maxConcurrency on a Pub/Sub subscription in code. It limits how many messages each service instance processes at once, so the total is that limit times the number of instances, which protects a database or an API. On GCP, Cloud Run services on an unordered topic use push delivery with adaptive concurrency instead. Encore provisions the topic and subscription in your AWS or GCP account.
Deploy to your cloud on AWS and Google Cloud
without managing infrastructure
Encore lets developers and agents define application infrastructure directly in code, then automatically provisions it from local development to production in your AWS or GCP account.