Skip to main content

Optimizing High-Velocity Telemetry with AWS DynamoDB

Photo of André Ferreira

André Ferreira

Senior Full-Stack Software Engineer • Feb 2026

Optimizing High-Velocity Telemetry with AWS DynamoDB

Real-time location and mapping for commercial fleets generates a continuous stream of events: position fixes, device heartbeats, quality-of-signal metadata, and derived features used downstream by analytics and operations. At Volkswagen Group Services, the stack centered on Python on AWS Lambda, Flask where a long-lived process was justified, DynamoDB as the system of record for hot paths, and AWS CDK to keep environments reproducible. The hardest problems were rarely "which service to call" and almost always access-pattern discipline and write amplification under burst traffic.

This article is a field report: how we thought about partitions, throttling, and client contracts, and how AppSync reduced API surface area without sacrificing query flexibility. For more on how I approach complex distributed and financial flows in other domains, see the notes on omnichannel DvP with Solidity and LayerZero and enterprise blockchain and IoT monetization. My full timeline and stack depth live on the about page.

Pipelines over point solutions

A common anti-pattern in telemetry work is to optimize each Lambda in isolation while the database absorbs unbounded variance. We treated the pipeline as the product: ingest, normalize, enrich, and persist with explicit SLOs on end-to-end latency and on cost per million events.

Lambda functions owned discrete steps—validation, deduplication keys, unit normalization, and fan-out to consumers. AWS CDK let us version infrastructure alongside application code, which matters when you are tuning capacity and alarms across several environments. Where Flask appeared, it was for controlled boundaries (tooling, internal dashboards, or bridging legacy integration shapes), not as a catch-all replacement for Lambda's elastic concurrency model.

The operational win came from making backpressure explicit: when downstream slowed, upstream workers needed to degrade predictably—batching, shedding non-critical attributes, or routing to cold storage—rather than retry-storming DynamoDB.

Express access patterns before GSIs

DynamoDB rewards upfront honesty about who reads what, how often, and with which key shape. We started every design conversation with a short table: primary access path, expected cardinality, growth rate, and whether the query was key-value, query on sort key, or scan (scans were treated as design failures unless strictly offline).

Global secondary indexes (GSIs) are powerful and expensive. Each GSI duplicates write throughput and storage in proportion to projected attributes. We delayed adding GSIs until a path was provably hot in production traces—not in architecture slides. When we added them, we projected only what the consumer needed to avoid silent storage creep.

Hot partitions and fleet-shaped traffic

Fleet telemetry often has natural skew: popular routes, depots, and time windows concentrate events. A naive partition key—say, vehicleId alone—can work until a subset of vehicles or regions dominates traffic. We combined keys and write sharding strategies where needed (for example, introducing a bounded suffix or time bucketing for extreme outliers) so no single partition sustained unbounded write rates.

The goal was never theoretical perfect uniformity; it was predictable throttling behavior and alarms that fired before customer-visible lag.

Write shaping, batching, and throttling

DynamoDB throttling is usually a signal that your request pattern disagrees with your capacity model. We invested in:

  • Batching at the application layer to amortize round trips, with caps so a single bad deploy could not create megabatch bombs.
  • Jittered retries with budgets; infinite retry loops against DynamoDB are a tax on the whole table.
  • Conditional writes only where invariants required them—each condition adds friction under load.

We also separated latency-sensitive paths from analytics-friendly paths. Not every derived field belongs in the same item or even the same table. Where clients tolerated seconds of delay, we used asynchronous enrichment so the critical write path stayed thin.

GraphQL with AppSync at the boundary

As client surfaces multiplied, a purely REST approach risked combinatorial endpoints or chatty hand-built BFFs. AWS AppSync gave us a single GraphQL edge with resolver logic tied to DynamoDB and other sources. Teams could fetch the graph they needed without forcing the backend to predict every screen permutation in advance.

The trade-off is operational: resolvers must stay strict, tested, and rate-aware. N+1 patterns do not disappear because the protocol is GraphQL—they migrate into resolver design. We paired AppSync with disciplined field-level authorization and observability (latency, error rates, and resolver-level metrics) so regressions were obvious in dashboards, not only in user reports.

Observability and cost as first-class requirements

High-velocity telemetry makes CloudWatch and structured logging non-optional. We correlated Lambda request IDs with pipeline stages and stored minimal diagnostic fingerprints (not full payloads) for incident response. Cost reviews included DynamoDB on-demand vs provisioned decisions per table, GSI burn, and data retention policies.

Cost and reliability are linked: a table that grows without compaction or TTL strategy becomes a liability—slower operations, higher backup costs, and fuzzier recovery drills.

Security and data minimization

Location data is sensitive. We enforced least-privilege IAM, encrypted data at rest, and minimized what each component could read. Cross-service contracts were reviewed when new consumers appeared—especially anything that looked like "just a quick join for analytics."

What I would revisit earlier

If I were repeating the program, I would push even harder on contract tests between producers and DynamoDB item shapes, and on chaos drills for partition-level hotspots before they appeared in peak season. I would also document GSIs as deprecatable artifacts with owners and sunset criteria, because indexes tend to outlive the features that justified them.

Stack snapshot

Python, AWS Lambda, AWS CDK, AppSync, DynamoDB, React, Redux, Apollo (GraphQL).

FAQ

How do you decide between DynamoDB on-demand and provisioned capacity?

Start with on-demand when traffic is unknown or spiky; move toward provisioned with autoscaling when you have stable baselines and need cost predictability. Re-evaluate after major product or fleet changes—telemetry profiles shift with routing algorithms and device firmware.

When does AppSync make sense versus a REST BFF?

When multiple clients need different projections of the same underlying data and you can invest in resolver governance. If you have one client and a handful of endpoints, REST may stay simpler.

What is the single biggest DynamoDB mistake in telemetry systems?

Designing the key schema from a diagram instead of from measured access patterns. The fix is always expensive once you are in production.

Where can I read more about your Web3 and integration work?

See Building omnichannel networks for finance institutions for cross-chain settlement patterns, and Blockchain-powered data monetization for enterprise IoT and billing integrations.

Engineering log, in your inbox.

Notes on full-stack delivery, Web3, and cloud architecture—same themes as the blog, without the noise.