Cloud Computing · Topic 7

Designing for 1,000 TPS Without Building for 1 Million

An interactive architecture whiteboard for engineering leadership and application owners. It shows how an existing Amazon API Gateway + AWS Lambda platform can sustain 1,000 transactions per second when the real constraint is the downstream systems, and why that does not call for blockchain-style sharding or a massive distributed compute layer.

Animations follow your system's reduced-motion setting until you choose otherwise. Every diagram works without animation.

A. Executive overview

"TPS" hides three different numbers. Most throughput incidents happen because a team measured one of them and assumed the other two.

Ingress throughput

How quickly requests can enter the platform: API Gateway, authentication, validation, enqueueing. Managed AWS services usually make this the easiest number to raise.

Processing throughput

How quickly transactions are completed end to end, including every downstream call. It's bounded by the slowest required step, often a legacy system.

Sustainable throughput

The rate the whole system can run at indefinitely while still meeting its latency, availability and data-integrity requirements. This is the number to design and test for.

Target arrival rate
1,000 TPS
Design target
Required sustained completion
1,000 TPS
Design target arrivals must be completed, not just accepted
Burst capacity
configurable
Set in the simulator; bounded by buffer durability and the API's acceptance contract
Downstream capacity (A · B · C)
configurable
TPS per system: legacy core · corporate banking · partner API. Measure, don't assume.
1,000 TPS is a design target, not a demonstrated resultNothing on this page has been load-tested against your systems. The numbers are planning inputs. Prove the target with service-specific capacity tests and an end-to-end load test before committing to it.
“Scale the ingress independently, control the processing rate, and remove or isolate downstream bottlenecks. A queue absorbs bursts; it does not create processing capacity.”

What 1,000 TPS means in practice

  • 86.4 million transactions per day at a sustained rate, or a much shorter peak window.
  • With 200 ms average processing time, about 200 transactions are in flight at any moment (Little's law: in-flight = rate × time).
  • If the legacy core sustains 300 TPS, no amount of Lambda concurrency completes 1,000 TPS of core-bound work. You must reduce, isolate, batch or partition that work.

The board-level answer

  • Keep API Gateway + Lambda for ingress. It is not the bottleneck.
  • Add durable queues, capped workers and downstream-specific adapters, so each system receives only what it can absorb.
  • Make async the default where the business contract allows it; keep a bounded, protected sync path where it doesn't.
  • Invest in idempotency, status tracking and reconciliation. That is where correctness lives.

B. Architecture comparison

Switch between the two architectures. Select any component (click it, or Tab to it and press Enter) to see its purpose, failure modes and operational trade-offs below the diagram.

asynchronous path synchronous path (bounded wait) HTTP 202 response status reads/writes dead-letter dashed box = optional
Recommended 1,000 TPS enterprise AWS architecture Corporate clients call Amazon API Gateway, optionally behind AWS WAF. Requests are authenticated, validated and rate-limited before an ingress Lambda. Synchronous operations follow a bounded-wait path straight to the legacy core's adapter. Asynchronous operations are written to a transaction status store, acknowledged with HTTP 202 and a correlation ID, and routed, optionally via EventBridge, to one SQS queue per downstream system. Capped worker pools and downstream-specific adapters call the legacy core, the corporate banking application and a partner API. Repeatedly failing messages go to dead-letter queues. Workers update the status store, and clients read it through a status API or callback. EDGE & INGRESS · scales out CONTROLLED PROCESSING · paced per system EXISTING SYSTEMS SYNCHRONOUS PATH · bounded wait · explicit timeout · fast 429/503 when saturated maxReceiveCount status updates write ACCEPTED + idempotency key HTTP 202 Accepted + correlation ID poll or callback status API reads the status store Corporateclients & apps AWS WAF API GatewayAmazon · REST/HTTP Auth · validaterate limit · quotas AWS Lambdaingress handler EventBridgeoptional SQS queue Alegacy core SQS queue Bcorp banking SQS queue Cpartner API Workers A≤ 60 in flight Workers B≤ 120 in flight Workers C≤ 40 in flight Adapter A≤ 300/s Adapter B≤ 600/s Adapter C≤ 200/s Legacy core~300 TPS Corp. banking~600 TPS Partner API~200 TPS quota DLQsone per queue Transaction status storeDynamoDB or existing DB Status APIGET /tx/{id} · callback what stays synchronous? what does 202 promise?
Recommended architecture. The example capacities (300 / 600 / 200 TPS) and worker limits are illustrative. Each worker limit ≈ downstream TPS × average call time. Click a component for details.

Side by side

Dimension1M TPS distributed (sharded)1K TPS enterprise AWS (recommended)
Where throughput comes fromPartitioning state and work across many shards that execute in parallelIndependent ingress scaling + controlled, isolated processing paced to each downstream system
Who owns the stateThe platform itself (each shard owns its slice)Existing systems of record you usually can't re-partition
Binding constraintNetwork, coordination, hot shardsLegacy and partner capacity, connection limits, latency
Consistency modelConsensus and finality across shardsSystems of record + idempotency + reconciliation
InfrastructureHundreds of always-on nodes (140 in the benchmark)Managed, mostly serverless services that scale with demand
Operational complexityVery high: distributed protocol operationsModerate: queues, alarms, DLQ runbooks, reconciliation
Fits when…You own a partitionable workload and must scale far beyond a single databaseYour target is ~1,000 TPS and the bottleneck is downstream capacity

C. Animated data flow

Requests are drawn as moving circles. ILLUSTRATIVE ANIMATION: not a live AWS or NEAR simulation. Rates and timings are scaled down so you can follow individual messages; the simulator below does the arithmetic at real scale.

request in flight queued (buffered) processing succeeded retry throttled (429) dead-lettered
429 + Retry-After Clientsbursty API GWrate limit Ingress λvalidate · enqueue Queue A · legacy core Workers A · max 2 Legacy core · slow done Queue B · banking Workers B · max 3 Corporate banking done Queue C · partner API Workers C · max 2 Partner API · flaky done Dead-letter queue (after 3 attempts) amber path = retry after visibility timeout
Arrived0
Accepted0
Throttled (429)0
Completed0
Retries0
Dead-lettered0
Queue A depth0
Queue B depth0
Queue C depth0

What you're seeing: 1K buffered architecture

  • Bursts arrive faster than the API's rate limit, so some requests are throttled with 429 at the edge: backpressure working as designed.
  • Accepted requests are buffered in one queue per downstream. Watch queue A grow during bursts and drain afterwards: the queue absorbs the burst, it doesn't speed anything up.
  • Each worker pool has a fixed cap (2, 3, 2), so the slow legacy core never sees more than 2 concurrent calls.
  • Partner failures retry after a visibility timeout. After 3 attempts the message is dead-lettered instead of blocking the lane.
  • Lane C's problems never slow lanes A and B: queue isolation and bulkheads.

Why the difference matters

The 1M design gets throughput by adding parallel owners of state. The 1K design gets safe throughput by pacing work to fixed-capacity owners of state. If you can't partition the system of record, more parallelism just moves the queue into the legacy system, where it shows up as timeouts.

D. Interactive throughput simulator

Educational approximationThis is a deterministic, steady-state model with documented formulas. It is not a substitute for load testing, queueing analysis or service-specific capacity testing, and it does not calculate real AWS limits, costs or production performance.
Presets:
Architecture
Traffic
Downstream capacity (sustainable TPS)
Workers
Advanced: workload shape, mix, timeout

Shares are normalised if they don't add up to 100%.

Incoming TPS
0
arrival rate during the burst
Accepted TPS
0
durably accepted (or answered, if sync)
Completed TPS
0
steady completion during the burst
Timed out / rejected
0
TPS (synchronous only)
Backlog growth
0
messages per second
Queue depth
0
at the end of the burst
Drain time
0
after the burst ends
Worker capacity
0
TPS = concurrency ÷ time
In flight (Little's law)
0
concurrency needed for the incoming rate
━ incoming vs ━ completed (TPS)
■ queue depth (messages)
downstream utilization (offered load ÷ capacity)
Model and assumptions (read before quoting any number)

Notation: λ = incoming TPS during the burst, λ₂ = arrival rate after it, T = burst duration, t = average processing time (s), N = worker concurrency, Dᵢ = sustainable capacity of downstream i, mᵢ = traffic share of branch i.

Worker capacity (TPS) W = N / t Concurrency in flight L = λ × t (Little's law) Branch arrival rate aᵢ = λ × mᵢ Serial chain capacity C = min(W, D_A, D_B, D_C) (every stage is required) Independent branches Cᵢ computed separately per branch (never multiplied into one chain) Queue growth rate g = max(0, accepted − completed) Queue depth after the burst Qᵢ = max(0, Q₀·mᵢ + (aᵢ − Cᵢ) × T) Drain time after the burst Qᵢ / (Cᵢ − λ₂·mᵢ) (∞ if Cᵢ ≤ λ₂·mᵢ)
  • 1 · Synchronous: each branch completes min(aᵢ, Dᵢ). Excess requests wait up to the timeout before failing, holding concurrency: demand = Σ completedᵢ·t + Σ excessᵢ·timeout. If demand exceeds N, every branch is scaled by N ÷ demand. This is how one slow system starves healthy ones in a shared synchronous pool. Accepted = completed; nothing is buffered.
  • 2 · Async, shared queue and workers: work advances in mix proportion, so capacity C = min(W, minᵢ Dᵢ ÷ mᵢ) (head-of-line blocking). Without per-downstream limits, workers offer W × mᵢ to each system while a backlog exists; above 100% that means errors and retries.
  • 3 · Per-downstream limits: concurrency is budgeted per system, demand first: baseᵢ = min(Dᵢ, aᵢ) × t (shared in proportion if N is too small). Any spare concurrency goes to systems that can use it to drain backlog, up to Dᵢ × t. Then Wᵢ = budgetᵢ ÷ t and Cᵢ = min(Dᵢ, Wᵢ). Offered load never exceeds Dᵢ.
  • 4 · Parallelized: as option 3, with Dᵢ multiplied by the partition count only for systems you mark as partitionable.
  • Rates are steady-state averages: no warm-up, cold starts, latency distributions, retries' extra load, or service quotas. Accepting faster than you complete assumes your buffer, message retention and API acceptance contract (202) allow it.
  • Charts integrate the same rates over time (240 steps); the time axis is capped at one hour after the burst.

E. Protecting non-scalable downstream systems

Getting to 1,000 TPS safely means making every layer respect the capacity of the slowest system it depends on. These fourteen controls work together. Open a card for where it belongs, when it helps, its limitations, and its effect on latency, throughput and reliability.

Exactly-once is an application property, not a broker featureSQS Standard delivers at least once. FIFO deduplication only removes duplicate messages sent within its deduplication window. Lambda retries, timeouts and partial batch failures can still invoke your code more than once. Exactly-once business effects (one debit per payment) require application-level idempotency keys, conditional writes or transactions, and reconciliation for ambiguous outcomes. No message broker guarantees them on its own.
Show:
1BackpressureStop upstream systems from generating unlimited work
Problem it solves
Producers can create work faster than it can be completed, which leads to unbounded queues, rising latency and eventually failure.
Where it belongs
At the API edge (429/503 with Retry-After), in the ingress Lambda (refuse new work when queue age exceeds the acceptance SLA), and between internal stages.
When it is useful
Whenever acceptance can outrun completion, which is always true for buffered designs.
Limitations
It moves the problem to callers, who must honour Retry-After with backoff and jitter. It needs a reliable saturation signal (queue age is better than depth).
Effect
Latency: protects p99 of accepted workThroughput: deliberately caps acceptanceReliability: ↑ prevents collapse
2Rate limitingEnforce sustainable rates globally and per downstream
Problem it solves
Demand above what a system can sustain, and noisy clients consuming a shared budget.
Where it belongs
API Gateway throttling and usage plans (per client and route); a token bucket in each downstream adapter (per system).
When it is useful
Always for legacy and partner systems with known or contracted capacity.
Limitations
Per-instance limiters multiply as workers scale out, so you need a shared limiter or a concurrency cap. Static limits drift from real capacity, so revisit them after every capacity test.
Effect
Latency: ↑ for queued workThroughput: capped at the safe rateReliability: ↑
3Concurrency limitsControl simultaneous calls into legacy systems
Problem it solves
Too many parallel calls exhaust connection pools, sessions or threads in the legacy system.
Where it belongs
The SQS event source mapping's maximum concurrency per queue, Lambda reserved concurrency, and adapter connection pools.
When it is useful
For systems with fixed connection limits. It is self-correcting: if the system slows down, rate = concurrency ÷ latency falls automatically.
Limitations
Concurrency isn't rate. Set it too low and you waste capacity; too high and it doesn't protect anything. Size it from Little's law and measured latency.
Effect
Latency: more stableThroughput: bounded by designReliability: ↑
4Queue isolationStop one slow system from blocking unrelated work
Problem it solves
Head-of-line blocking: with one shared queue, messages for a slow or failing system occupy workers and delay everything else.
Where it belongs
One queue (and DLQ) per downstream or per transaction class, routed by the ingress or EventBridge rules.
When it is useful
Mixed workloads with different capacities, SLAs or failure rates. Compare options 2 and 3 in the simulator.
Limitations
More queues to operate and monitor; no ordering guarantees across queues; routing logic must stay correct.
Effect
Latency: ↓ for healthy lanesThroughput: ↑ healthy lanes unaffectedReliability: ↑ failures contained
5BatchingReduce per-transaction overhead where the backend supports it
Problem it solves
Per-call overhead (connection, authentication, commit) dominates, so the system spends its capacity on ceremony.
Where it belongs
SQS batch receive (batch size and batching window), plus an adapter that aggregates items into the backend's bulk API.
When it is useful
Only when the backend genuinely supports bulk operations and the latency budget allows a short wait.
Limitations
Partial failures are complex (use ReportBatchItemFailures). The batching window adds latency, and a failed call affects many transactions.
Effect
Latency: ↑ by the batch windowThroughput: ↑ often substantiallyReliability: mixed
6IdempotencyPrevent duplicate business operations during retries
Problem it solves
At-least-once delivery, client retries and Lambda retries can otherwise post the same payment twice.
Where it belongs
The API (Idempotency-Key header); ingress (conditional write of the key); the worker before the downstream call; and the downstream itself when it accepts an idempotency reference.
When it is useful
Always, for every state-changing operation.
Limitations
Needs a durable key store with a TTL and a defined answer for "same key, different payload". It can't make a non-idempotent downstream safe on its own, so you also need reconciliation.
Effect
Latency: + one conditional writeThroughput: neutralReliability: ↑↑ correctness
7Dead-letter queuesIsolate repeatedly failing messages
Problem it solves
Poison messages retry forever, wasting worker and downstream capacity and hiding real failures.
Where it belongs
A redrive policy on every SQS queue (maxReceiveCount); on-failure destinations for async Lambda invocations.
When it is useful
Always for asynchronous processing.
Limitations
A DLQ is a parking lot, not a fix. It needs alarms, triage runbooks and a redrive process. Dead-lettering breaks ordering, and messages still expire at the retention limit.
Effect
Throughput: ↑ stops wasted workReliability: ↑Latency: ↑ for the failed items
8Timeouts & circuit breakersPrevent cascading failures
Problem it solves
A slow dependency ties up callers until everything upstream also slows down or fails.
Where it belongs
In every adapter call. Keep timeouts nested: downstream call < Lambda timeout < queue visibility timeout. Use one circuit breaker per downstream.
When it is useful
On every remote call, and especially on synchronous paths.
Limitations
A timeout after the request was sent leaves the outcome unknown (it may have committed), so you need reconciliation. Breaker thresholds need tuning, and breaker state is per instance unless you share it.
Effect
Latency: boundedThroughput: protectedReliability: ↑
9BulkheadsSeparate resources and concurrency budgets by dependency
Problem it solves
One dependency consumes a shared pool (concurrency, connections, threads), starving everything else. The synchronous model in the simulator shows this.
Where it belongs
Separate functions or event source mappings with their own concurrency, separate connection pools, separate API keys and quotas, and separate sync and async capacity.
When it is useful
When there are several dependencies with different reliability, and whenever sync and async traffic share infrastructure.
Limitations
Reserved capacity can sit idle, and there is more configuration to maintain.
Effect
Reliability: ↑Throughput: ↑ for healthy pathsCost: some idle headroom
10CachingOnly where data freshness and business semantics allow
Problem it solves
Repeated reads of slowly changing reference data load the legacy system for no benefit.
Where it belongs
In the adapter or API layer (in-memory, ElastiCache, DAX, or API Gateway caching for safe GETs).
When it is useful
Read-heavy reference data (product catalogues, static entitlements) with an agreed staleness.
Limitations
Staleness, invalidation and stampedes. Never cache balances, limits or authorization decisions unless the business explicitly accepts stale answers.
Effect
Latency: ↓Throughput: ↑ for readsReliability: mixed (stale data risk)
11PartitioningBy customer, account, transaction type or another valid key
Problem it solves
A single serial stream or a single resource limits throughput while ordering must still be preserved.
Where it belongs
FIFO message group IDs per account or customer, separate queues per key range, and downstream instances that genuinely own disjoint data.
When it is useful
When ordering matters only per key and the downstream can process keys independently (option 4 in the simulator).
Limitations
Hot keys and cross-partition transactions remain a problem. Partitioning does not raise the capacity of a single legacy database behind all partitions.
Effect
Throughput: ↑ parallel keysOrdering: per keyLatency: ↓ except hot keys
12AutoscalingScale workers on demand and queue age, within downstream limits
Problem it solves
Fixed worker counts either waste money or fall behind during peaks.
Where it belongs
Lambda scales with the queue via the event source mapping; container consumers scale on backlog per task or age of the oldest message.
When it is useful
When demand varies, provided the scaling is capped by each downstream's concurrency budget.
Limitations
Scaling consumers past downstream capacity only adds errors and retries. There is also scaling lag and cold starts to account for.
Effect
Throughput: ↑ up to the capCost: efficientReliability: ↑ only when capped
13Durable transaction stateAccepted, processing, succeeded, failed, reconciliation-required
Problem it solves
Neither clients nor operators can tell what happened to a transaction, and blind retries create duplicates.
Where it belongs
A status store keyed by correlation ID, written at ingress and on every transition with conditional updates (no regressions from a late retry).
When it is useful
For all asynchronous processing, auditability and customer support.
Limitations
Extra writes per transaction, retention and PII governance, and the store itself needs capacity planning.
Effect
Latency: + smallThroughput: neutralReliability: ↑↑ traceability
14ReconciliationRecover from ambiguous outcomes
Problem it solves
A timeout after sending: the downstream may have succeeded even though you never got the response.
Where it belongs
A scheduled or event-driven job that queries the downstream by business reference (or compares statements) and resolves RECONCILIATION_REQUIRED to succeeded or failed.
When it is useful
For any non-idempotent downstream, and always for money movement.
Limitations
Requires a way to query outcomes (an API, reports or statements). Resolution is delayed, and a human process is needed for the leftovers.
Effect
Correctness: ↑↑Latency: ↑ for ambiguous casesThroughput: neutral

F. Queue and worker design

N failed receives redrive after fix write ACCEPTED PROCESSING / SUCCEEDED / FAILED query outcome API Gatewaythrottle per client Ingress Lambdavalidate · enqueue Amazon SQSdurable buffer Worker poolcapped concurrency Downstream adapterlimit · timeout · breaker Legacy systemfixed sustainable capacity Dead-letter queuealarm · triage · redrive Transaction status storekeyed by correlation ID · conditional transitions Reconciliation jobresolves unknown outcomes
The full async path with its failure and recovery paths. Every arrow into the status store is a conditional write, so a late retry can never move a transaction backwards.

Settings that make or break this design

SettingGuidanceWhy
Visibility timeout≥ 6× the consumer Lambda timeout (AWS guidance for SQS event sources)Otherwise a message reappears while it's still being processed, causing duplicate work
Timeout nestingdownstream call < Lambda timeout < visibility timeoutEach layer must give up before the layer above assumes failure
maxReceiveCountTypically 3–5, with the DLQ alarmed at > 0 messagesBounded retries; poison messages leave the main flow
Event source mapping maximum concurrencyPer queue ≈ downstream sustainable TPS × average call timeThis is the knob that protects each legacy system
Partial batch responsesEnable ReportBatchItemFailuresOnly failed items are retried, not the whole batch
Batch size / windowSmall for latency-sensitive work; larger only with real bulk benefitBatching trades latency for throughput
Message retentionLonger than your worst realistic backlog + incident recovery timeA backlog that outlives retention silently loses accepted work
Reserved concurrencyReserve for sync and async functions separatelyKeeps the regional concurrency pool from becoming a shared single point of failure

The differences that matter

Accepted ≠ processed ≠ completed

Accepted: durably recorded and queued (HTTP 202). Processed: a worker attempted it. Completed: the downstream confirmed the business effect. Report all three. Ingress dashboards that show only "accepted" hide a growing backlog.

Retries happen at three layers

Clients retry, the SDK retries, and SQS redelivers. Uncoordinated, they multiply load during an incident. Pick one owner for business retries (the queue), cap the others, and make every layer idempotent.

Reserved concurrency vs maximum concurrency

Lambda reserved concurrency guarantees and caps a function's share of the regional pool. Event source mapping maximum concurrency caps how many concurrent invocations one SQS queue drives, so you can protect a downstream without throttling the function itself.

SQS StandardSQS FIFO
DeliveryAt least once; occasional duplicatesDeduplicated within the deduplication window (still make consumers idempotent)
OrderingBest effortStrict within a message group (e.g. per account)
ThroughputVery highLower per queue; batching and high-throughput mode raise it (check current quotas)
Failure impactOne bad message doesn't block othersA failing message blocks its message group until it succeeds or is dead-lettered
Choose whenOrder doesn't matter, or can be restored downstreamPer-key ordering is a business requirement (e.g. sequential postings on one account)

Transaction status state machine

timeout: outcome unknown confirmed posted confirmed not posted retry with backoff ACCEPTED PROCESSING SUCCEEDED FAILED non-retryable, or retries exhausted → DLQ RECONCILIATION_REQUIRED
Clients see these states through the status API. Only reconciliation may move a transaction out of RECONCILIATION_REQUIRED.

G. Synchronous vs asynchronous API contracts

Not every transaction can be asynchronous. A real-time authorisation, a balance check before a trade, or an instant-payment confirmation needs a definitive answer now, and it stays synchronous unless the business contract changes. Everything else should default to async.

Asynchronous: accept, then complete

POST /v1/payments Idempotency-Key: 7f3c9a2e-1b4d-4e88-9c1a-52d0e6a1b9f4 { "debtor": "ACC-1001", "amount": "2500.00", "currency": "EUR" } HTTP/1.1 202 Accepted Location: /v1/payments/txn_01HZX4Q8 { "correlationId": "txn_01HZX4Q8", "status": "ACCEPTED" } GET /v1/payments/txn_01HZX4Q8 HTTP/1.1 200 OK { "status": "SUCCEEDED", "completedAt": "2026-10-12T09:41:07Z" }

202 means "durably recorded and queued", nothing more. Repeating the POST with the same key returns the same correlation ID instead of creating a second payment.

Synchronous: bounded wait, explicit overload

POST /v1/authorisations Idempotency-Key: 0b5e… (client timeout: 3 s) HTTP/1.1 200 OK ← answered within the bound HTTP/1.1 429 Too Many Requests Retry-After: 2 ← over quota: shed early, cheaply HTTP/1.1 503 Service Unavailable Retry-After: 5 ← breaker open / downstream saturated HTTP/1.1 504 Gateway Timeout ← outcome UNKNOWN: reconcile, don't blindly retry

Fail fast with 429/503 rather than letting requests queue until they time out. A 504 after the request was sent is an ambiguous outcome: retry only with the same idempotency key, and reconcile.

QuestionIf yes
Does the caller need the business outcome before it can continue (and can't proceed on "accepted")?Synchronous, with a bounded wait and reserved capacity
Can the business accept "we have it, the result follows within N seconds"?Asynchronous: 202 + status endpoint or callback
Is the downstream occasionally slower than the caller's timeout?Prefer async; if it must stay sync, add a circuit breaker and reconciliation
Is the operation a bulk or batch submission?Asynchronous, almost always

H. Observability and capacity validation

QuestionSignal (CloudWatch metric or custom)Alarm idea
Are we accepting what arrives?API Gateway Count, 4XXError (429s), 5XXError, Latency429 rate above the agreed shed level; 5XX > 0.5%
Are we completing what we accept?Accepted vs completed per minute (custom, from the status store or EMF)Completed < accepted for N consecutive minutes
How far behind are we?SQS ApproximateAgeOfOldestMessage, ApproximateNumberOfMessagesVisibleOldest message age > completion SLA (age beats depth)
Are workers saturated or throttled?Lambda ConcurrentExecutions, Throttles, Duration, ErrorsThrottles > 0 on sync functions; duration approaching timeout
Is a downstream struggling?Per-adapter latency p50/p99, error rate, breaker state (custom)p99 latency > budget; breaker open
Are we losing or parking work?DLQ ApproximateNumberOfMessagesVisible, RECONCILIATION_REQUIRED countAny message in a DLQ; reconciliation backlog growing

How to actually prove 1,000 TPS

  1. Measure each downstream aloneFind each system's sustainable TPS and latency curve, and the point where latency turns non-linear, in a production-like environment, with the owners' agreement.
  2. Set budgets from measurementsPer-downstream rate limits and concurrency = measured sustainable capacity minus safety headroom (e.g. 20–30%).
  3. Check AWS quotasRegional Lambda concurrency, API Gateway throttles, and SQS/FIFO throughput for your exact configuration. Request increases before the test, not during it.
  4. Load test end to endRamp to 1,000 TPS with a realistic transaction mix, then hold it long enough to see steady state, then run bursts above it.
  5. Test the failure modesSlow one downstream, fail another, and confirm isolation, DLQ behaviour, alarms and reconciliation.
  6. Record the result as a measured numberOnly now does "1,000 TPS" stop being a design target.

I. Recommendation and roadmap

Keep the existing API Gateway + Lambda platform. Reach 1,000 TPS by buffering asynchronous work, pacing each downstream to its measured capacity, protecting the synchronous path, and making every transaction idempotent and traceable. Reserve sharding-style redesigns for workloads you own end to end and that genuinely need far more than a few thousand TPS.
If you observe…Do this firstNot this
Ingress 429s while downstreams are idleRaise API Gateway and Lambda limits; check quotasAdd queues (the bottleneck is elsewhere)
Queue age keeps growingFind the binding downstream; isolate it; batch or partition if it supports thatAdd more workers to a saturated legacy system
Timeouts on the sync pathBounded waits, breaker, 429/503 shedding, reserved concurrency, reconciliationLonger timeouts
Duplicate business effectsIdempotency keys end to end + conditional status writesSwitching to FIFO and assuming the problem is solved
One partner outage slows everythingQueue per downstream + bulkheads + DLQA bigger shared worker pool
  1. Phase 1 · Make it observable (weeks 1–2)Accepted vs completed, queue age, per-downstream latency and errors. Baseline each downstream's sustainable capacity.
  2. Phase 2 · Make it safe (weeks 2–6)Idempotency keys, status store, per-downstream queues + DLQs, worker concurrency caps, adapter rate limits, timeouts and breakers.
  3. Phase 3 · Make it async where allowed (weeks 4–10)Introduce 202 + status/callback for operations whose contract allows it; keep a protected sync path for the rest.
  4. Phase 4 · Raise the ceiling (ongoing)Batching, caching of reference data, partitioning where the downstream supports it, and capacity work with system owners. Re-run the load test after each change.

Self-check quiz

Score: 0 / 0 answered

1 · The legacy core sustains 300 TPS. You add an SQS queue in front of it and accept 1,000 TPS of core-bound traffic for an hour. What happens?
C. A queue absorbs bursts; it doesn't create processing capacity. Sustained arrivals above capacity just grow the backlog (about 2.5 million messages after an hour).
2 · Which control most directly prevents a slow partner API from delaying legacy-core transactions?
B. Isolation stops head-of-line blocking and resource starvation. Compare simulator options 2 and 3 at the same load.
3 · With 250 concurrent workers and 200 ms average processing time, what is the worker capacity?
D. Capacity = concurrency ÷ time = 250 ÷ 0.2 s = 1,250 TPS. Whether that is usable still depends on each downstream's capacity.
4 · A worker times out calling the core after sending a payment. What is the correct handling?
A. A timeout after sending is an ambiguous outcome. Guessing either way risks a duplicate payment or a lost one.
5 · Does SQS FIFO give you exactly-once business effects?
C. Exactly-once business effects are an application property built on idempotency keys, conditional writes and reconciliation.
6 · Why isn't the NEAR 1M TPS benchmark a template for an enterprise API that calls legacy banking systems?
B. Different constraint, different solution: sharding helps when you own partitionable state; pacing and protection help when the bottleneck is downstream.