This expert level session covers best practices and tips on how to reduce latency to the absolute minimum when dealing with high volume, high speed datasets, using Amazon DynamoDB. We take a deep dive into the design patterns and access patterns geared to provide low latency at very high throughput. We cover some ways in which customers have achieved low latencies and have a customer speak about their experience of using DynamoDB at scale.
25. WebstoreOrders
Hash
Customer ID
Range
Timestamp
Attrib
Items ordered
Attrib
Order ID
Attrib
Household ID
Household Index
Hash
HouseholdID
Range
Timestamp
Attrib
Items ordered
Attrib
Order ID
Attrib
Customer ID
Indexing
27. Dayof Order Index
Hash
Dayof order
Range
Order ID
Attrib
Items ordered
Attrib
Customer ID
Attrib
Timestamp
WebstoreOrders
Hash
Customer ID
Range
Timestamp
Attrib
Items ordered
Attrib
Order ID
Attrib
Day of order
Indexing
28. Day of order index
Table
Partition 1
Partition 3
Partition 2
…
Index
Partition 1
Partition 3
Partition 2
…
Client
Client
Client
New orders
29. Day of order index
Table
Partition 1
Partition 3
Partition 2
Index
Partition 1
Partition 3
Partition 2
Client
Client
Client
New orders
…
…
30.
31. Alternate Approach: Scanning
H: Alice
R: Oct 2
Partition #1
Partition #2
H: Alice
R: Nov 11
H: Alice
R: Dec 25
H: Bob
R: Oct 20
H: Bob
R: Nov 12
H: Bob
R: Dec 23
P1
P2
P3
P4
P5
P6
P7
P8
P9
Scan
32. •Delete old items from the client side
H: Alice
R: Oct 2
Partition #1
Partition #2
H: Alice
R: Nov 11
H: Alice
R: Dec 25
H: Bob
R: Oct 20
H: Bob
R: Nov 12
H: Bob
R: Dec 23
•Takeaway: Table growth can impact throughput per key
•Important when:Accumulating infrequently-read data
33.
34. •Controlling table growth with deletes works but…
•Deleting items from client = 2x write cost!
•Can we achieve cheaper deletes AND scans?
H: Alice
R: Oct 2
Partition #1
Partition #2
H: Alice
R: Nov 11
H: Alice
R: Dec 25
H: Bob
R: Oct 20
H: Bob
R: Nov 12
H: Bob
R: Dec 23
Scan for last month
35. H: Alice
R: Dec 23
Dec Table
Hash: Bob
R: Dec 25
H: Alice
R: Oct 2
Oct Table
Hash: Bob
R: Oct 20
•Takeaway: Time series data chunks very well
•Important when: Big, growingtime series tables
H: Alice
R: Nov 11
Nov Table
Hash: Bob
R: Nov 12
Scan last month
58. TestPacket Response Record
Hash Key (string)
Test Packet ID
Range Key (string)
Test PacketResponse ID
Attribute (string)
Create Timestamp
Attribute (string)
PostDate
Attribute (string)
Response JSON