Why this matters
- VaultCommerce's order microservice collapsed five tables into one
VaultCommercetable — fewer cross-table transactions, one on-call surface, lower latency for "load my account page." - The trade-off is cognitive: every engineer must read the access-pattern matrix before adding an entity.
- GSIs on the same table provide inverted lookups (email → user) while keeping writes atomic within a partition where possible.
Partition key: USER#42Routes to shard
Items in partition
ORDER#2026-001Sort key
ORDER#2026-002Sort key
PROFILESort key
Key overloading pattern
{ "PK": "USER#42", "SK": "PROFILE", "email": "alice@vault.test", "tier": "GOLD" }
{ "PK": "USER#42", "SK": "ORDER#2026-0042", "total": 129.99, "status": "PAID" }
{ "PK": "USER#42", "SK": "WISHLIST#SKU-8842", "addedAt": "2026-04-01" }
{ "PK": "PRODUCT#SKU-8842", "SK": "METADATA", "title": "Trail Pack", "price": 89 }
Single-table conventions
PK— partition anchor (USER#id,PRODUCT#sku,ORDER#id).SK— entity discriminator and sort order (PROFILE,ORDER#date,METADATA).- GSI1 — inverted lookups (
GSI1PK=EMAIL#alice@vault.test→ find user). - Type attribute — optional
entityType: "Order"for client-side filtering.
One Query PK=USER#42 with SK begins_with prefixes assembles the account dashboard.
The rest of this guide is part of Pro
Free covers every fresher guide in full. Pro unlocks Senior, Staff and Architect guides across every track.
Still to come · 2 sections
- Access pattern matrix
- Write pattern with denormalization
Test yourself
Answer these before moving on — recall is what makes it stick.