SlideShare ist ein Scribd-Unternehmen logo
1 von 100
Downloaden Sie, um offline zu lesen
©2015,  Amazon  Web  Services,  Inc.  or  its  affiliates.  All  rights  reserved
Deep Dive: Amazon DynamoDB
Fitz (Philip Fitzsimons)
Solutions Architecture
Amazon Web Services
Agenda
•  Tables, API, data types, indexes
•  Scaling
•  Data modeling
•  Scenarios and best practices
•  Customer Story
•  DynamoDB Streams
•  Reference architecture
Amazon DynamoDB
•  Managed NoSQL database service
•  Supports both document and key-value data models
•  Highly scalable
•  Consistent, single-digit millisecond latency at any
scale
•  Highly available—3x replication
•  Simple and powerful API
Tables, API, Data Types
Table
Table
Items
AAributes
Hash
Key
Range
Key
Mandatory
Key-value access pattern
Determines data distribution Optional
Model 1:N relationships
Enables rich query capabilities
All  items  for  a  hash  key
==,  <,  >,  >=,  <=
“begins  with”
“between”
sorted  results
counts
top/boAom  N  values
paged  responses
•  CreateTable
•  UpdateTable
•  DeleteTable
•  DescribeTable
•  ListTables
•  GetItem
•  Query
•  Scan
•  BatchGetItem
•  PutItem
•  UpdateItem
•  DeleteItem
•  BatchWriteItem
•  ListStreams
•  DescribeStream
•  GetShardIterator
•  GetRecords
Table and item API
Stream API
DynamoDB
In preview
Data types
•  String (S)
•  Number (N)
•  Binary (B)
•  String Set (SS)
•  Number Set (NS)
•  Binary Set (BS)
•  Boolean (BOOL)
•  Null (NULL)
•  List (L)
•  Map (M)
Used for storing nested JSON documents
00 55 A954 AA FF
Hash table
•  Hash key uniquely identifies an item
•  Hash key is used for building an unordered hash index
•  Table can be partitioned for scale
00 FF
Id = 1
Name = Jim
Hash (1) = 7B
Id = 2
Name = Andy
Dept = Engg
Hash (2) = 48
Id = 3
Name = Kim
Dept = Ops
Hash (3) = CD
Key Space
Partitions are three-way replicated
Id = 2
Name = Andy
Dept = Engg
Id = 3
Name = Kim
Dept = Ops
Id = 1
Name = Jim
Id = 2
Name = Andy
Dept = Engg
Id = 3
Name = Kim
Dept = Ops
Id = 1
Name = Jim
Id = 2
Name = Andy
Dept = Engg
Id = 3
Name = Kim
Dept = Ops
Id = 1
Name = Jim
Replica 1
Replica 2
Replica 3
Partition 1 Partition 2 Partition N
Hash-range table
•  Hash key and range key together uniquely identify an Item
•  Within unordered hash index, data is sorted by the range key
•  No limit on the number of items (∞) per hash key
–  Except if you have local secondary indexes
00:0 FF:∞
Hash (2) = 48
Customer# = 2
Order# = 10
Item = Pen
Customer# = 2
Order# = 11
Item = Shoes
Customer# = 1
Order# = 10
Item = Toy
Customer# = 1
Order# = 11
Item = Boots
Hash (1) = 7B
Customer# = 3
Order# = 10
Item = Book
Customer# = 3
Order# = 11
Item = Paper
Hash (3) = CD
55 A9:∞54:∞ AA
Partition 1 Partition 2 Partition 3
Indexes
Local secondary index (LSI)
•  Alternate range key attribute
•  Index is local to a hash key (or partition)
A1	
  
(hash)	
  
A3	
  
(range)	
  
A2	
  
(table	
  key)	
  
A1	
  
(hash)	
  
A2	
  
(range)	
  
A3	
  A4	
  A5	
  
LSIs A1	
  
(hash)	
  
A4	
  
(range)	
  
A2	
  
(table	
  key)	
  
A3	
  
(projected)	
  
Table
KEYS_ONLY
INCLUDE A3
A1	
  
(hash)	
  
A5	
  
(range)	
  
A2	
  
(table	
  key)	
  
A3	
  
(projected)	
  
A4	
  
(projected)	
   ALL
10 GB max per hash
key, i.e. LSIs limit the
# of range keys!
Global secondary index (GSI)
•  Alternate hash (+range) key
•  Index is across all table hash keys (partitions)
A1	
  
(hash)	
  
A2	
  A3	
  A4	
  A5	
  
GSIs A5	
  
(hash)	
  
A4	
  
(range)	
  
A1	
  
(table	
  key)	
  
A3	
  
(projected)	
  
Table
INCLUDE A3
A4	
  
(hash)	
  
A5	
  
(range)	
  
A1	
  
(table	
  key)	
  
A2	
  
(projected)	
  
A3	
  
(projected)	
   ALL
A2	
  
(hash)	
  
A1	
  
(table	
  key)	
   KEYS_ONLY
RCUs/WCUs
provisioned separately
for GSIs
Online indexing
How do GSI updates work?
Table
Primary
table
Primary
table
Primary
table
Primary
table
Global
Secondary
Index
Client
1. Update request
2. Asynchronous
update (in progress)
2. Update response
If GSIs don’t have enough write capacity, table writes will be throttled!
LSI or GSI?
•  LSI can be modeled as a GSI
•  If data size in an item collection > 10 GB, use GSI
•  If eventual consistency is okay for your
scenario, use GSI!
Scaling
Scaling
•  Throughput
–  Provision any amount of throughput to a table
•  Size
–  Add any number of items to a table
•  Max item size is 400 KB
•  LSIs limit the number of range keys due to 10 GB limit
•  Scaling is achieved through partitioning
Throughput
•  Provisioned at the table level
–  Write capacity units (WCUs) are measured in 1 KB per second
–  Read capacity units (RCUs) are measured in 4 KB per second
•  RCUs measure strictly consistent reads
•  Eventually consistent reads cost 1/2 of consistent reads
•  Read and write throughput limits are
independent
WCURCU
Partitioning math
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  =  ​ 𝑇 𝑎𝑏𝑙𝑒   𝑆𝑖𝑧𝑒   𝑖𝑛   𝐺𝐵/10   𝐺𝐵 
( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒)
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠
( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡)
=      ​​ 𝑅 𝐶𝑈↓𝑓𝑜𝑟   𝑟𝑒𝑎𝑑𝑠 /3000   𝑅𝐶𝑈   +  ​​ 𝑊 𝐶𝑈↓𝑓𝑜𝑟   𝑤𝑟𝑖𝑡𝑒𝑠 /
1000   𝑊𝐶𝑈 
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠=​MAX⁠​# 𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  ⁠  # 𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  
( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡)( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒)( 𝑡𝑜𝑡𝑎𝑙)
In the future, these details might change…
Partitioning example
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  =  ​8   𝐺𝐵/10   𝐺𝐵  = 0.8 = 1
( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒)
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠
( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡)
=      ​​5000↓𝑅𝐶𝑈 /3000   𝑅𝐶𝑈   +  ​​500↓𝑊𝐶𝑈 /1000   𝑊𝐶𝑈  =
2.17 = 3
Table  size  =  8  GB,  RCUs  =  5000,  WCUs  =  500
#   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠=​MAX⁠​1   𝑓𝑜𝑟   𝑠𝑖𝑧𝑒⁠  3   𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡  
( 𝑡𝑜𝑡𝑎𝑙)
RCUs  per  partition  =  5000/3  =  1666.67
WCUs  per  partition  =  500/3  =    166.67
Data/partition  =  8/3  =  2.66  GB
RCUs and WCUs are uniformly
spread across partitions
Getting the most out of DynamoDB throughput
“To get the most out of
DynamoDB throughput, create
tables where the hash key
element has a large number of
distinct values, and values are
requested fairly uniformly, as
randomly as possible.”
—DynamoDB Developer Guide
•  Space: access is evenly
spread over the key-space
•  Time: requests arrive evenly
spaced in time
Example: hot keys
Partition
Time
Heat
Example: periodic spike
How does DynamoDB handle bursts?
•  DynamoDB saves 300 seconds of unused
capacity per partition
•  This is used when a partition runs out of
provisioned throughput due to bursts
–  Provided excess capacity is available at the node
Burst capacity is built-in
0
400
800
1200
1600
CapacityUnits
Time
Provisioned Consumed
“Save up” unused capacity
Consume saved up capacity
Burst capacity: 300 seconds
(1200 × 300 = 3600 CU)
Burst capacity may not be sufficient
0
400
800
1200
1600
CapacityUnits
Time
Provisioned Consumed Attempted
Burst capacity: 300 seconds
(1200 × 300 = 3600 CU)
Throttled requests
Don’t completely depend on burst capacity… provision sufficient throughput
What causes throttling?
•  If sustained throughput goes beyond
provisioned throughput per partition
•  From the example before:
–  Table created with 5000 RCUs, 500 WCUs
–  RCUs per partition = 1666.67
–  WCUs per partition = 166.67
–  If sustained throughput > (1666 RCUs or 166 WCUs) per key or
partition, DynamoDB may throttle requests
•  Solution: Increase provisioned throughput
What causes throttling?
•  Non-uniform workloads
–  Hot keys/hot partitions
–  Very large bursts
•  Dilution of throughout across partitions caused
by mixing hot data with cold data
–  Use a table per time period for storing time series data so WCUs
and RCUs are applied to the hot data set
Data Modeling
Store data based on how you will access it!
1:1 relationships or key-values
•  Use a table with a hash key
•  Use GetItem or BatchGetItem API
Example: Given a user or email, get attributes
Users	
  Table	
  
Hash	
  key	
   A/ributes	
  
UserId	
  =	
  bob	
   Email	
  =	
  bob@gmail.com,	
  JoinDate	
  =	
  2011-­‐11-­‐15	
  
UserId	
  =	
  fred	
   Email	
  =	
  fred@yahoo.com,	
  JoinDate	
  =	
  2011-­‐12-­‐01	
  
Users-­‐Email-­‐GSI	
  
Hash	
  key	
   A/ributes	
  
Email	
  =	
  bob@gmail.com	
   UserId	
  =	
  bob,	
  JoinDate	
  =	
  2011-­‐11-­‐15	
  
Email	
  =	
  fred@yahoo.com	
   UserId	
  =	
  fred,	
  JoinDate	
  =	
  2011-­‐12-­‐01	
  
1:N relationships or parent-children
•  Use a table with hash and range key
•  Use Query API
Example:
–  Given a device, find all readings between epoch X, Y
Device-­‐measurements	
  
Hash	
  Key	
   Range	
  key	
   A/ributes	
  
DeviceId	
  =	
  1	
   epoch	
  =	
  5513A97C	
   Temperature	
  =	
  30,	
  pressure	
  =	
  90	
  
DeviceId	
  =	
  1	
   epoch	
  =	
  5513A9DB	
   Temperature	
  =	
  30,	
  pressure	
  =	
  90	
  
N:M relationships
•  Use a table and GSI with hash and range key
elements switched
•  Use Query API
Example: Given a user, find all games. Or given a
game, find all users.
User-­‐Games-­‐Table	
  
Hash	
  Key	
   Range	
  key	
  
UserId	
  =	
  bob	
   GameId	
  =	
  Game1	
  
UserId	
  =	
  fred	
   GameId	
  =	
  Game2	
  
UserId	
  =	
  bob	
   GameId	
  =	
  Game3	
  
Game-­‐Users-­‐GSI	
  
Hash	
  Key	
   Range	
  key	
  
GameId	
  =	
  Game1	
   UserId	
  =	
  bob	
  
GameId	
  =	
  Game2	
   UserId	
  =	
  fred	
  
GameId	
  =	
  Game3	
   UserId	
  =	
  bob	
  
Documents (JSON)
•  New data types (M, L, BOOL,
NULL) introduced to support
JSON
•  Document SDKs
–  Simple programming model
–  Conversion to/from JSON
–  Java, JavaScript, Ruby, .NET
•  Cannot index (S,N) elements
of a JSON object stored in M
–  They need to be modeled as
top-level table attributes to be
used in LSIs and GSIs
Javascript DynamoDB
string S
number N
boolean BOOL
null NULL
array L
object M
Rich expressions
•  Projection expression
–  Query/Get/Scan: ProductReviews.FiveStar[0]
•  Filter expression
–  Query/Scan: #V > :num (#V is a place holder for keyword VIEWS)
•  Conditional expression
–  Put/Update/DeleteItem: attribute_not_exists (#pr.FiveStar)
•  Update expression
–  UpdateItem: set Replies = Replies + :num
Scenarios and Best Practices
Event Logging
Storing time series data
Time series tables
Events_table_2015_April
Event_id
(Hash key)
Timestamp
(range key)
Attribute1 …. Attribute N
Events_table_2015_March
Event_id
(Hash key)
Timestamp
(range key)
Attribute1 …. Attribute N
Events_table_2015_Feburary
Event_id
(Hash key)
Timestamp
(range key)
Attribute1 …. Attribute N
Events_table_2015_January
Event_id
(Hash key)
Timestamp
(range key)
Attribute1 …. Attribute N
RCUs = 1000
WCUs = 100
RCUs = 10000
WCUs = 10000
RCUs = 100
WCUs = 1
RCUs = 10
WCUs = 1
Current table
Older tables
HotdataColddata
Don’t mix hot and cold data; archive cold data to Amazon S3
Use a table per time period
•  Pre-create daily, weekly, monthly tables
•  Provision required throughput for current table
•  Writes go to the current table
•  Turn off (or reduce) throughput for older tables
Dealing with time series data
Product Catalog
Popular items (read)
Partition 1
2000 RCUs
Partition K
2000 RCUs
Partition M
2000 RCUs
Partition 50
2000 RCU
Scaling bottlenecks
Product A Product B
Shoppers
ProductCatalog Table
100,000↓𝑅𝐶𝑈 /​50↓𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠      ≈𝟐𝟎𝟎𝟎    
𝑅𝐶𝑈   𝑝𝑒𝑟   𝑝𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛
SELECT Id,
Description, ...
FROM ProductCatalog
WHERE Id="POPULAR_PRODUCT"
RequestsPerSecond
Item Primary Key
Request Distribution Per Hash Key
DynamoDB Requests
Partition 1 Partition 2
ProductCatalog Table
User
DynamoDB
User
SELECT Id,
Description, ...
FROM ProductCatalog
WHERE Id="POPULAR_PRODUCT"
RequestsPerSecond
Item Primary Key
Request Distribution Per Hash Key
DynamoDB Requests Cache Hits
Messaging App
Large items
Filters vs. indexes
M:N Modeling—inbox and outbox
Messages
Table
Messages App
David
SELECT *
FROM Messages
WHERE Recipient='David'
LIMIT 50
ORDER BY Date DESC
Inbox
SELECT *
FROM Messages
WHERE Sender ='David'
LIMIT 50
ORDER BY Date DESC
Outbox
Recipient Date Sender Message
David 2014-10-02 Bob …
… 48 more messages for David …
David 2014-10-03 Alice …
Alice 2014-09-28 Bob …
Alice 2014-10-01 Carol …
Large and small attributes mixed
(Many more messages)
David
Messages Table
50 items × 256 KB each
Large message bodies
Attachments
SELECT *
FROM Messages
WHERE Recipient='David'
LIMIT 50
ORDER BY Date DESC
Inbox
​50↓𝑖𝑡𝑒𝑚𝑠 ×​256↓𝐾𝐵 ×  ​​1↓𝑅𝐶𝑈 /​4↓𝐾𝐵  ×  ​​1↓𝑟𝑒𝑎𝑑 /​2↓𝑒. 𝑐.   𝑟𝑒𝑎𝑑𝑠  =​ 𝟏 𝟔𝟎𝟎↓𝑹𝑪𝑼 
Computing inbox query cost
Items evaluated by query
Average item size
Conversion ratio
Eventually consistent reads
Recipient Date Sender Subject MsgId
David 2014-10-02 Bob Hi!… afed
David 2014-10-03 Alice RE: The… 3kf8
Alice 2014-09-28 Bob FW: Ok… 9d2b
Alice 2014-10-01 Carol Hi!... ct7r
Separate the bulk data
Inbox-GSI Messages Table
MsgId Body
9d2b …
3kf8 …
ct7r …
afed …
David
1.  Query Inbox-GSI: 1 RCU
2.  BatchGetItem Messages: 1600 RCU
(50 separate items at 256 KB)
(50 sequential items at 128 bytes)
Uniformly distributes large item reads
Inbox GSI
Simplified writes
David
PutItem
{
MsgId: 123,
Body: ...,
Recipient: Steve,
Sender: David,
Date: 2014-10-23,
...
}
Inbox
Global secondary
index
Messages
Table
Outbox Sender
Outbox GSI
SELECT *
FROM Messages
WHERE Sender ='David'
LIMIT 50
ORDER BY Date DESC
Messaging app
Messages
Table
David
Inbox
Global secondary
index
Inbox
Outbox
Global secondary
index
Outbox
•  Reduce one-to-many item sizes
•  Configure secondary index projections
•  Use GSIs to model M:N relationship
between sender and recipient
Distribute large items
Querying many large items at
once
InboxMessagesOutbox
Multiplayer Online Gaming
Query filters vs.
composite key indexes
GameId Date Host Opponent Status
d9bl3 2014-10-02 David Alice DONE
72f49 2014-09-30 Alice Bob PENDING
o2pnb 2014-10-08 Bob Carol IN_PROGRESS
b932s 2014-10-03 Carol Bob PENDING
ef9ca 2014-10-03 David Bob IN_PROGRESS
Games Table
Multiplayer online game data
Query for incoming game requests
•  DynamoDB indexes provide hash and range
•  What about queries for two equalities and a
range?
SELECT * FROM Game
WHERE Opponent='Bob‘
AND Status=‘PENDING'
ORDER BY Date DESC
(hash)
(range)
(?)
Secondary Index
Opponent Date GameId Status Host
Alice 2014-10-02 d9bl3 DONE David
Carol 2014-10-08 o2pnb IN_PROGRESS Bob
Bob 2014-09-30 72f49 PENDING Alice
Bob 2014-10-03 b932s PENDING Carol
Bob 2014-10-03 ef9ca IN_PROGRESS David
Approach 1: Query filter
Bob
Secondary Index
Approach 1: Query filter
Bob
Opponent Date GameId Status Host
Alice 2014-10-02 d9bl3 DONE David
Carol 2014-10-08 o2pnb IN_PROGRESS Bob
Bob 2014-09-30 72f49 PENDING Alice
Bob 2014-10-03 b932s PENDING Carol
Bob 2014-10-03 ef9ca IN_PROGRESS David
SELECT * FROM Game
WHERE Opponent='Bob'
ORDER BY Date DESC
FILTER ON Status='PENDING'
(filtered out)
Needle in a haystack
Bob
•  Send back less data “on the wire”
•  Simplify application code
•  Simple SQL-like expressions
–  AND, OR, NOT, ()
Use query filter
Your index isn’t entirely selective
Approach 2: Composite key
StatusDate
DONE_2014-10-02
IN_PROGRESS_2014-10-08
IN_PROGRESS_2014-10-03
PENDING_2014-09-30
PENDING_2014-10-03
Status
DONE
IN_PROGRESS
IN_PROGRESS
PENDING
PENDING
Date
2014-10-02
2014-10-08
2014-10-03
2014-10-03
2014-09-30
Secondary Index
Approach 2: Composite key
Opponent StatusDate GameId Host
Alice DONE_2014-10-02 d9bl3 David
Carol IN_PROGRESS_2014-10-08 o2pnb Bob
Bob IN_PROGRESS_2014-10-03 ef9ca David
Bob PENDING_2014-09-30 72f49 Alice
Bob PENDING_2014-10-03 b932s Carol
Opponent StatusDate GameId Host
Alice DONE_2014-10-02 d9bl3 David
Carol IN_PROGRESS_2014-10-08 o2pnb Bob
Bob IN_PROGRESS_2014-10-03 ef9ca David
Bob PENDING_2014-09-30 72f49 Alice
Bob PENDING_2014-10-03 b932s Carol
Secondary Index
Approach 2: Composite key
Bob
SELECT * FROM Game
WHERE Opponent='Bob'
AND StatusDate BEGINS_WITH 'PENDING'
Needle in a sorted haystack
Bob
Sparse indexes
Id	
  	
  
(Hash)	
  
User	
   Game	
  Score	
  Date	
   Award	
  
1	
   Bob	
   G1	
   1300	
   2012-­‐12-­‐23	
  
2	
   Bob	
   G1	
   1450	
   2012-­‐12-­‐23	
  
3	
   Jay	
   G1	
   1600	
   2012-­‐12-­‐24	
  
4	
   Mary	
   G1	
   2000	
   2012-­‐10-­‐24	
   Champ	
  
5	
   Ryan	
   G2	
   123	
   2012-­‐03-­‐10	
  
6	
   Jones	
  G2	
   345	
   2012-­‐03-­‐20	
  
Game-scores-table
Award	
  	
  
(Hash)	
  
Id	
   User	
   Score	
  
Champ	
   4	
   Mary	
   2000	
  
Award-GSI
Scan sparse hash GSIs
•  Concatenate attributes to form useful
secondary index keys
•  Take advantage of sparse indexes
Replace filter with indexes
You want to optimize a query as
much as possible
Status + Date
Customer Story: JustGiving
AWS Big Data Platform
Overview
Richard Freeman, PhD
Senior Data Scientist / Architect
richard.freeman@justgiving.com
69
We are
A tech-for-good company that is
Connecting the World’s
Causes
with People who
Care
DONATIONS
$3bn of donations raised since launch, $576m in 2014
CHARITIES
20,000 charities on the platform
USERS
23m users have made a transaction
REACH
Givers in 164 countries donate to causes in 12 countries
DATA
Billions of data points
AMAZON WEB SERVICES
Production environment micro-services and big data analytics,
reporting and KPIs
The Challenge
•  Data sources: clickstream, logs, data warehouse, and
external data sources
•  Data too big and SQL queries too complex for data
warehouse
•  Machine Learning algorithms at scale
•  Generate KPI and interactive reports
New Data Science Use Cases
•  High throughput
•  Live view in near real-time
•  Scale out
•  Minimum maintenance
Web Events
Real Time Web Analytics with Kinesis and DynamoDB
The Outcome
• Live view on the data
• Fast to query and scales out
• Minimum support and maintenance
• Needed a pattern to maximise throughput of temporal data
DynamoDB
• AWS services managed cloud services and SDKs
• New pattern: Resilient and incremental data loads into many
Redshift clusters in parallel
• One Redshift cluster per stakeholder, e.g. business, data
scientist, analysts, DBAs
• Scale out and run complex queries and machine learning
algorithms
RAVEN platform:
Scalable reporting and analytics cloud platform
Thank you!
We are hiring!
Contact:
Richard.freeman
@justgiving.com
Derived computations
Real-Time Voting
Write-heavy items
Requirements for voting
•  Allow each person to vote only once
•  No changing votes
•  Real-time aggregation
•  Voter analytics, demographics
Real-time voting architecture
AggregateVotes
Table
Voters
RawVotes Table
Voting App
Partition 1
1000 WCUs
Partition K
1000 WCUs
Partition M
1000 WCUs
Partition N
1000 WCUs
Votes Table
Candidate A Candidate B
Scaling bottlenecks
Voters
Provision 200,000 WCUs
Write sharding
Candidate A_2
Candidate B_1
Candidate B_2
Candidate B_3
Candidate B_5
Candidate B_4
Candidate B_7
Candidate B_6
Candidate A_1
Candidate A_3
Candidate A_4
Candidate A_7 Candidate B_8
Candidate A_6 Candidate A_8
Candidate A_5
Voter
Votes Table
Write sharding
Candidate A_2
Candidate B_1
Candidate B_2
Candidate B_3
Candidate B_5
Candidate B_4
Candidate B_7
Candidate B_6
Candidate A_1
Candidate A_3
Candidate A_4
Candidate A_7 Candidate B_8
UpdateItem: “CandidateA_” + rand(0, 200)
ADD 1 to Votes
Candidate A_6 Candidate A_8
Candidate A_5
Voter
Votes Table
Votes Table
Shard aggregation
Candidate A_2
Candidate B_1
Candidate B_2
Candidate B_3
Candidate B_5
Candidate B_4
Candidate B_7
Candidate B_6
Candidate A_1
Candidate A_3
Candidate A_4
Candidate A_5
Candidate A_6 Candidate A_8
Candidate A_7 Candidate B_8
Periodic
Process
Candidate A
Total: 2.5M
1. Sum
2. Store Voter
•  Trade off read cost for write scalability
•  Consider throughput per hash key and per
partition
Shard write-heavy hash keys
Your write workload is not
horizontally scalable
Correctness in voting
UserId Candidate Date
Alice A 2013-10-02
Bob B 2013-10-02
Eve B 2013-10-02
Chuck A 2013-10-02
RawVotes Table
Segment Votes
A_1 23
B_2 12
B_1 14
A_2 25
AggregateVotes Table
Voter
1. Record vote and de-dupe; retry 2. Increment candidate counter
Correctness in aggregation?
UserId Candidate Date
Alice A 2013-10-02
Bob B 2013-10-02
Eve B 2013-10-02
Chuck A 2013-10-02
RawVotes Table
Segment Votes
A_1 23
B_2 12
B_1 14
A_2 25
AggregateVotes Table
Voter
DynamoDB Streams
•  Stream of updates to
a table
•  Asynchronous
•  Exactly once
•  Strictly ordered
–  Per item
•  Highly durable
•  Scale with table
•  24-hour lifetime
•  Sub-second latency
DynamoDB Streams
View Type Destination
Old image—before update Name = John, Destination = Mars
New image—after update Name = John, Destination = Pluto
Old and new images Name = John, Destination = Mars
Name = John, Destination = Pluto
Keys only Name = John
View types
UpdateItem (Name = John, Destination = Pluto)
Stream
Table
Partition 1
Partition 2
Partition 3
Partition 4
Partition 5
Table
Shard 1
Shard 2
Shard 3
Shard 4
KCL
Worker
KCL
Worker
KCL
Worker
KCL
Worker
Amazon Kinesis Client
Library Application
DynamoDB
Client Application
Updates
DynamoDB Streams and
Amazon Kinesis Client Library
DynamoDB Streams
Open Source Cross-
Region Replication Library
Asia Pacific (Sydney) EU (Ireland) Replica
US East (N. Virginia)
Cross-region replication
DynamoDB Streams and AWS Lambda
Real-time voting architecture (improved)
AggregateVotes
Table
Amazon
Redshift Amazon EMR
Your 
Amazon Kinesis–
Enabled App
Voters RawVotes TableVoting App RawVotes
DynamoDB
Stream
Real-time voting architecture
AggregateVotes
Table
Amazon
Redshift Amazon EMR
Your 
Amazon Kinesis-
Enabled App
Voters RawVotes TableVoting App RawVotes
DynamoDB
Stream
Real-time voting architecture
AggregateVotes
Table
Amazon
Redshift Amazon EMR
Your 
Amazon Kinesis-
Enabled app
Voters RawVotes TableVoting App RawVotes
DynamoDB
Stream
Real-time voting architecture
AggregateVotes
Table
Amazon
Redshift Amazon EMR
Your 
Amazon Kinesis–
Enabled App
Voters RawVotes TableVoting app RawVotes
DynamoDB
Stream
Real-time voting architecture
AggregateVotes
Table
Amazon
Redshift Amazon EMR
Your 
Amazon Kinesis–
Enabled App
Voters RawVotes TableVoting app RawVotes
DynamoDB
Stream
Analytics with
DynamoDB Streams
•  Collect and de-dupe data in DynamoDB
•  Aggregate data in-memory and flush
periodically
Performing real-time aggregation
and analytics
Architecture
Reference Architecture
LONDON

Weitere ähnliche Inhalte

Was ist angesagt?

BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon Redshift
BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon RedshiftBDA306 Building a Modern Data Warehouse: Deep Dive on Amazon Redshift
BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon RedshiftAmazon Web Services
 
Ceh v8 labs module 03 scanning networks
Ceh v8 labs module 03 scanning networksCeh v8 labs module 03 scanning networks
Ceh v8 labs module 03 scanning networksAsep Sopyan
 
Brute force-attack presentation
Brute force-attack presentationBrute force-attack presentation
Brute force-attack presentationMahmoud Ibra
 
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교Amazon Web Services Korea
 
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...Amazon Web Services Korea
 
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...Amazon Web Services Korea
 
HTTP Request Header and HTTP Status Code
HTTP Request Header and HTTP Status CodeHTTP Request Header and HTTP Status Code
HTTP Request Header and HTTP Status CodeAbhishek L.R
 
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017Amazon Web Services Korea
 
Amazon Athena Capabilities and Use Cases Overview
Amazon Athena Capabilities and Use Cases Overview Amazon Athena Capabilities and Use Cases Overview
Amazon Athena Capabilities and Use Cases Overview Amazon Web Services
 
Authentication & Authorization for Connected Mobile & Web Applications using ...
Authentication & Authorization for Connected Mobile & Web Applications using ...Authentication & Authorization for Connected Mobile & Web Applications using ...
Authentication & Authorization for Connected Mobile & Web Applications using ...Amazon Web Services
 
Brute force attack
Brute force attackBrute force attack
Brute force attackjoycruiser
 
Amazon EFS (Elastic File System) 이해하고사용하기
Amazon EFS (Elastic File System) 이해하고사용하기Amazon EFS (Elastic File System) 이해하고사용하기
Amazon EFS (Elastic File System) 이해하고사용하기Amazon Web Services Korea
 
The top 10 windows logs event id's used v1.0
The top 10 windows logs event id's used v1.0The top 10 windows logs event id's used v1.0
The top 10 windows logs event id's used v1.0Michael Gough
 
Rest API Security
Rest API SecurityRest API Security
Rest API SecurityStormpath
 
Deep Dive and Best Practices for Real Time Streaming Applications
Deep Dive and Best Practices for Real Time Streaming ApplicationsDeep Dive and Best Practices for Real Time Streaming Applications
Deep Dive and Best Practices for Real Time Streaming ApplicationsAmazon Web Services
 
Introduction To OWASP
Introduction To OWASPIntroduction To OWASP
Introduction To OWASPMarco Morana
 

Was ist angesagt? (20)

BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon Redshift
BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon RedshiftBDA306 Building a Modern Data Warehouse: Deep Dive on Amazon Redshift
BDA306 Building a Modern Data Warehouse: Deep Dive on Amazon Redshift
 
Ceh v8 labs module 03 scanning networks
Ceh v8 labs module 03 scanning networksCeh v8 labs module 03 scanning networks
Ceh v8 labs module 03 scanning networks
 
Brute force-attack presentation
Brute force-attack presentationBrute force-attack presentation
Brute force-attack presentation
 
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
 
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...
IAM 정책을 잘 알아야 AWS 보안도 쉬워진다. 이것은 꼭 알고 가자! - 신은수 솔루션즈 아키텍트, AWS :: AWS Summit S...
 
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...
진화하는 CloudFront 의 이해와 글로벌 서비스 활용 - 안수일 시니어 솔루션즈 아키텍트, GS NEOTEK :: AWS Summit...
 
Intro to AWS: Database Services
Intro to AWS: Database ServicesIntro to AWS: Database Services
Intro to AWS: Database Services
 
HTTP Request Header and HTTP Status Code
HTTP Request Header and HTTP Status CodeHTTP Request Header and HTTP Status Code
HTTP Request Header and HTTP Status Code
 
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017
천만 사용자를 위한 AWS 클라우드 아키텍쳐 진화하기- AWS Summit Seoul 2017
 
OAuth 2.0 Security Reinforced
OAuth 2.0 Security ReinforcedOAuth 2.0 Security Reinforced
OAuth 2.0 Security Reinforced
 
Introduction to Amazon EC2
Introduction to Amazon EC2Introduction to Amazon EC2
Introduction to Amazon EC2
 
Amazon Athena Capabilities and Use Cases Overview
Amazon Athena Capabilities and Use Cases Overview Amazon Athena Capabilities and Use Cases Overview
Amazon Athena Capabilities and Use Cases Overview
 
Introduction to Amazon S3
Introduction to Amazon S3Introduction to Amazon S3
Introduction to Amazon S3
 
Authentication & Authorization for Connected Mobile & Web Applications using ...
Authentication & Authorization for Connected Mobile & Web Applications using ...Authentication & Authorization for Connected Mobile & Web Applications using ...
Authentication & Authorization for Connected Mobile & Web Applications using ...
 
Brute force attack
Brute force attackBrute force attack
Brute force attack
 
Amazon EFS (Elastic File System) 이해하고사용하기
Amazon EFS (Elastic File System) 이해하고사용하기Amazon EFS (Elastic File System) 이해하고사용하기
Amazon EFS (Elastic File System) 이해하고사용하기
 
The top 10 windows logs event id's used v1.0
The top 10 windows logs event id's used v1.0The top 10 windows logs event id's used v1.0
The top 10 windows logs event id's used v1.0
 
Rest API Security
Rest API SecurityRest API Security
Rest API Security
 
Deep Dive and Best Practices for Real Time Streaming Applications
Deep Dive and Best Practices for Real Time Streaming ApplicationsDeep Dive and Best Practices for Real Time Streaming Applications
Deep Dive and Best Practices for Real Time Streaming Applications
 
Introduction To OWASP
Introduction To OWASPIntroduction To OWASP
Introduction To OWASP
 

Andere mochten auch

(DAT401) Amazon DynamoDB Deep Dive
(DAT401) Amazon DynamoDB Deep Dive(DAT401) Amazon DynamoDB Deep Dive
(DAT401) Amazon DynamoDB Deep DiveAmazon Web Services
 
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)Amazon Web Services
 
Design Patterns using Amazon DynamoDB
 Design Patterns using Amazon DynamoDB Design Patterns using Amazon DynamoDB
Design Patterns using Amazon DynamoDBAmazon Web Services
 
SOLR Power FTW: short version
SOLR Power FTW: short versionSOLR Power FTW: short version
SOLR Power FTW: short versionAlex Pinkin
 
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...Lucidworks
 
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...Amazon Web Services
 
Cassandra under the hood
Cassandra under the hoodCassandra under the hood
Cassandra under the hoodAndriy Rymar
 
Amazon Aurora: Amazon’s New Relational Database Engine
Amazon Aurora: Amazon’s New Relational Database EngineAmazon Aurora: Amazon’s New Relational Database Engine
Amazon Aurora: Amazon’s New Relational Database EngineAmazon Web Services
 
Building Applications with DynamoDB
Building Applications with DynamoDBBuilding Applications with DynamoDB
Building Applications with DynamoDBAmazon Web Services
 

Andere mochten auch (16)

Data Access Patterns
Data Access PatternsData Access Patterns
Data Access Patterns
 
(DAT401) Amazon DynamoDB Deep Dive
(DAT401) Amazon DynamoDB Deep Dive(DAT401) Amazon DynamoDB Deep Dive
(DAT401) Amazon DynamoDB Deep Dive
 
Deep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDBDeep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDB
 
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)
AWS re:Invent 2016: Deep Dive on Amazon DynamoDB (DAT304)
 
Design Patterns using Amazon DynamoDB
 Design Patterns using Amazon DynamoDB Design Patterns using Amazon DynamoDB
Design Patterns using Amazon DynamoDB
 
Living with garbage
Living with garbageLiving with garbage
Living with garbage
 
SOLR Power FTW: short version
SOLR Power FTW: short versionSOLR Power FTW: short version
SOLR Power FTW: short version
 
AWS Webcast - Dynamo DB
AWS Webcast - Dynamo DBAWS Webcast - Dynamo DB
AWS Webcast - Dynamo DB
 
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...
High Performance Solr and JVM Tuning Strategies used for MapQuest’s Search Ah...
 
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...
Amazon DynamoDB Design Patterns for Ultra-High Performance Apps (DAT304) | AW...
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDBDeep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 
Cassandra under the hood
Cassandra under the hoodCassandra under the hood
Cassandra under the hood
 
Amazon Aurora: Amazon’s New Relational Database Engine
Amazon Aurora: Amazon’s New Relational Database EngineAmazon Aurora: Amazon’s New Relational Database Engine
Amazon Aurora: Amazon’s New Relational Database Engine
 
Building Applications with DynamoDB
Building Applications with DynamoDBBuilding Applications with DynamoDB
Building Applications with DynamoDB
 
Deep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDBDeep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDB
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDBDeep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 

Ähnlich wie Deep Dive - DynamoDB

Amazon Dynamo DB for Developers (김일호) - AWS DB Day
Amazon Dynamo DB for Developers (김일호) - AWS DB DayAmazon Dynamo DB for Developers (김일호) - AWS DB Day
Amazon Dynamo DB for Developers (김일호) - AWS DB DayAmazon Web Services Korea
 
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAmazon Web Services
 
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016Amazon Web Services Korea
 
February 2016 Webinar Series - Introduction to DynamoDB
February 2016 Webinar Series - Introduction to DynamoDBFebruary 2016 Webinar Series - Introduction to DynamoDB
February 2016 Webinar Series - Introduction to DynamoDBAmazon Web Services
 
Deep Dive into DynamoDB
Deep Dive into DynamoDBDeep Dive into DynamoDB
Deep Dive into DynamoDBAWS Germany
 
初探AWS 平台上的 NoSQL 雲端資料庫服務
初探AWS 平台上的 NoSQL 雲端資料庫服務初探AWS 平台上的 NoSQL 雲端資料庫服務
初探AWS 平台上的 NoSQL 雲端資料庫服務Amazon Web Services
 
Getting Started with Amazon DynamoDB
Getting Started with Amazon DynamoDBGetting Started with Amazon DynamoDB
Getting Started with Amazon DynamoDBAmazon Web Services
 
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB Day
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB DayGetting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB Day
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB DayAmazon Web Services Korea
 
Building your data warehouse with Redshift
Building your data warehouse with RedshiftBuilding your data warehouse with Redshift
Building your data warehouse with RedshiftAmazon Web Services
 
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 GamingAmazon Web Services Korea
 
AWS July Webinar Series - Getting Started with Amazon DynamoDB
AWS July Webinar Series - Getting Started with Amazon DynamoDBAWS July Webinar Series - Getting Started with Amazon DynamoDB
AWS July Webinar Series - Getting Started with Amazon DynamoDBAmazon Web Services
 
(WRK302) Event-Driven Programming
(WRK302) Event-Driven Programming(WRK302) Event-Driven Programming
(WRK302) Event-Driven ProgrammingAmazon Web Services
 

Ähnlich wie Deep Dive - DynamoDB (20)

Amazon DynamoDB 深入探討
Amazon DynamoDB 深入探討Amazon DynamoDB 深入探討
Amazon DynamoDB 深入探討
 
Amazon Dynamo DB for Developers (김일호) - AWS DB Day
Amazon Dynamo DB for Developers (김일호) - AWS DB DayAmazon Dynamo DB for Developers (김일호) - AWS DB Day
Amazon Dynamo DB for Developers (김일호) - AWS DB Day
 
DynamodbDB Deep Dive
DynamodbDB Deep DiveDynamodbDB Deep Dive
DynamodbDB Deep Dive
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDBDeep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
 
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
 
February 2016 Webinar Series - Introduction to DynamoDB
February 2016 Webinar Series - Introduction to DynamoDBFebruary 2016 Webinar Series - Introduction to DynamoDB
February 2016 Webinar Series - Introduction to DynamoDB
 
Data Collection and Storage
Data Collection and StorageData Collection and Storage
Data Collection and Storage
 
Deep Dive into DynamoDB
Deep Dive into DynamoDBDeep Dive into DynamoDB
Deep Dive into DynamoDB
 
初探AWS 平台上的 NoSQL 雲端資料庫服務
初探AWS 平台上的 NoSQL 雲端資料庫服務初探AWS 平台上的 NoSQL 雲端資料庫服務
初探AWS 平台上的 NoSQL 雲端資料庫服務
 
AWS Data Collection & Storage
AWS Data Collection & StorageAWS Data Collection & Storage
AWS Data Collection & Storage
 
Getting Started with Amazon DynamoDB
Getting Started with Amazon DynamoDBGetting Started with Amazon DynamoDB
Getting Started with Amazon DynamoDB
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB Day
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB DayGetting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB Day
Getting Strated with Amazon Dynamo DB (Jim Scharf) - AWS DB Day
 
Building your data warehouse with Redshift
Building your data warehouse with RedshiftBuilding your data warehouse with Redshift
Building your data warehouse with Redshift
 
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming
게임을 위한 DynamoDB 사례 및 팁 - 김일호 솔루션즈 아키텍트:: AWS Cloud Track 3 Gaming
 
AWS July Webinar Series - Getting Started with Amazon DynamoDB
AWS July Webinar Series - Getting Started with Amazon DynamoDBAWS July Webinar Series - Getting Started with Amazon DynamoDB
AWS July Webinar Series - Getting Started with Amazon DynamoDB
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDBDeep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 
Deep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDBDeep Dive on Amazon DynamoDB
Deep Dive on Amazon DynamoDB
 
(WRK302) Event-Driven Programming
(WRK302) Event-Driven Programming(WRK302) Event-Driven Programming
(WRK302) Event-Driven Programming
 

Mehr von Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

Mehr von Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Kürzlich hochgeladen

How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESmohitsingh558521
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 

Kürzlich hochgeladen (20)

How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 

Deep Dive - DynamoDB

  • 1. ©2015,  Amazon  Web  Services,  Inc.  or  its  affiliates.  All  rights  reserved Deep Dive: Amazon DynamoDB Fitz (Philip Fitzsimons) Solutions Architecture Amazon Web Services
  • 2. Agenda •  Tables, API, data types, indexes •  Scaling •  Data modeling •  Scenarios and best practices •  Customer Story •  DynamoDB Streams •  Reference architecture
  • 3. Amazon DynamoDB •  Managed NoSQL database service •  Supports both document and key-value data models •  Highly scalable •  Consistent, single-digit millisecond latency at any scale •  Highly available—3x replication •  Simple and powerful API
  • 5. Table Table Items AAributes Hash Key Range Key Mandatory Key-value access pattern Determines data distribution Optional Model 1:N relationships Enables rich query capabilities All  items  for  a  hash  key ==,  <,  >,  >=,  <= “begins  with” “between” sorted  results counts top/boAom  N  values paged  responses
  • 6. •  CreateTable •  UpdateTable •  DeleteTable •  DescribeTable •  ListTables •  GetItem •  Query •  Scan •  BatchGetItem •  PutItem •  UpdateItem •  DeleteItem •  BatchWriteItem •  ListStreams •  DescribeStream •  GetShardIterator •  GetRecords Table and item API Stream API DynamoDB In preview
  • 7. Data types •  String (S) •  Number (N) •  Binary (B) •  String Set (SS) •  Number Set (NS) •  Binary Set (BS) •  Boolean (BOOL) •  Null (NULL) •  List (L) •  Map (M) Used for storing nested JSON documents
  • 8. 00 55 A954 AA FF Hash table •  Hash key uniquely identifies an item •  Hash key is used for building an unordered hash index •  Table can be partitioned for scale 00 FF Id = 1 Name = Jim Hash (1) = 7B Id = 2 Name = Andy Dept = Engg Hash (2) = 48 Id = 3 Name = Kim Dept = Ops Hash (3) = CD Key Space
  • 9. Partitions are three-way replicated Id = 2 Name = Andy Dept = Engg Id = 3 Name = Kim Dept = Ops Id = 1 Name = Jim Id = 2 Name = Andy Dept = Engg Id = 3 Name = Kim Dept = Ops Id = 1 Name = Jim Id = 2 Name = Andy Dept = Engg Id = 3 Name = Kim Dept = Ops Id = 1 Name = Jim Replica 1 Replica 2 Replica 3 Partition 1 Partition 2 Partition N
  • 10. Hash-range table •  Hash key and range key together uniquely identify an Item •  Within unordered hash index, data is sorted by the range key •  No limit on the number of items (∞) per hash key –  Except if you have local secondary indexes 00:0 FF:∞ Hash (2) = 48 Customer# = 2 Order# = 10 Item = Pen Customer# = 2 Order# = 11 Item = Shoes Customer# = 1 Order# = 10 Item = Toy Customer# = 1 Order# = 11 Item = Boots Hash (1) = 7B Customer# = 3 Order# = 10 Item = Book Customer# = 3 Order# = 11 Item = Paper Hash (3) = CD 55 A9:∞54:∞ AA Partition 1 Partition 2 Partition 3
  • 12. Local secondary index (LSI) •  Alternate range key attribute •  Index is local to a hash key (or partition) A1   (hash)   A3   (range)   A2   (table  key)   A1   (hash)   A2   (range)   A3  A4  A5   LSIs A1   (hash)   A4   (range)   A2   (table  key)   A3   (projected)   Table KEYS_ONLY INCLUDE A3 A1   (hash)   A5   (range)   A2   (table  key)   A3   (projected)   A4   (projected)   ALL 10 GB max per hash key, i.e. LSIs limit the # of range keys!
  • 13. Global secondary index (GSI) •  Alternate hash (+range) key •  Index is across all table hash keys (partitions) A1   (hash)   A2  A3  A4  A5   GSIs A5   (hash)   A4   (range)   A1   (table  key)   A3   (projected)   Table INCLUDE A3 A4   (hash)   A5   (range)   A1   (table  key)   A2   (projected)   A3   (projected)   ALL A2   (hash)   A1   (table  key)   KEYS_ONLY RCUs/WCUs provisioned separately for GSIs Online indexing
  • 14. How do GSI updates work? Table Primary table Primary table Primary table Primary table Global Secondary Index Client 1. Update request 2. Asynchronous update (in progress) 2. Update response If GSIs don’t have enough write capacity, table writes will be throttled!
  • 15. LSI or GSI? •  LSI can be modeled as a GSI •  If data size in an item collection > 10 GB, use GSI •  If eventual consistency is okay for your scenario, use GSI!
  • 17. Scaling •  Throughput –  Provision any amount of throughput to a table •  Size –  Add any number of items to a table •  Max item size is 400 KB •  LSIs limit the number of range keys due to 10 GB limit •  Scaling is achieved through partitioning
  • 18. Throughput •  Provisioned at the table level –  Write capacity units (WCUs) are measured in 1 KB per second –  Read capacity units (RCUs) are measured in 4 KB per second •  RCUs measure strictly consistent reads •  Eventually consistent reads cost 1/2 of consistent reads •  Read and write throughput limits are independent WCURCU
  • 19. Partitioning math #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  =  ​ 𝑇 𝑎𝑏𝑙𝑒   𝑆𝑖𝑧𝑒   𝑖𝑛   𝐺𝐵/10   𝐺𝐵  ( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒) #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠 ( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡) =      ​​ 𝑅 𝐶𝑈↓𝑓𝑜𝑟   𝑟𝑒𝑎𝑑𝑠 /3000   𝑅𝐶𝑈   +  ​​ 𝑊 𝐶𝑈↓𝑓𝑜𝑟   𝑤𝑟𝑖𝑡𝑒𝑠 / 1000   𝑊𝐶𝑈  #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠=​MAX⁠​# 𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  ⁠  # 𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠   ( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡)( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒)( 𝑡𝑜𝑡𝑎𝑙) In the future, these details might change…
  • 20. Partitioning example #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠  =  ​8   𝐺𝐵/10   𝐺𝐵  = 0.8 = 1 ( 𝑓𝑜𝑟   𝑠𝑖𝑧𝑒) #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠 ( 𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡) =      ​​5000↓𝑅𝐶𝑈 /3000   𝑅𝐶𝑈   +  ​​500↓𝑊𝐶𝑈 /1000   𝑊𝐶𝑈  = 2.17 = 3 Table  size  =  8  GB,  RCUs  =  5000,  WCUs  =  500 #   𝑜𝑓   𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠=​MAX⁠​1   𝑓𝑜𝑟   𝑠𝑖𝑧𝑒⁠  3   𝑓𝑜𝑟   𝑡ℎ𝑟𝑜𝑢𝑔ℎ𝑝𝑢𝑡   ( 𝑡𝑜𝑡𝑎𝑙) RCUs  per  partition  =  5000/3  =  1666.67 WCUs  per  partition  =  500/3  =    166.67 Data/partition  =  8/3  =  2.66  GB RCUs and WCUs are uniformly spread across partitions
  • 21. Getting the most out of DynamoDB throughput “To get the most out of DynamoDB throughput, create tables where the hash key element has a large number of distinct values, and values are requested fairly uniformly, as randomly as possible.” —DynamoDB Developer Guide •  Space: access is evenly spread over the key-space •  Time: requests arrive evenly spaced in time
  • 24. How does DynamoDB handle bursts? •  DynamoDB saves 300 seconds of unused capacity per partition •  This is used when a partition runs out of provisioned throughput due to bursts –  Provided excess capacity is available at the node
  • 25. Burst capacity is built-in 0 400 800 1200 1600 CapacityUnits Time Provisioned Consumed “Save up” unused capacity Consume saved up capacity Burst capacity: 300 seconds (1200 × 300 = 3600 CU)
  • 26. Burst capacity may not be sufficient 0 400 800 1200 1600 CapacityUnits Time Provisioned Consumed Attempted Burst capacity: 300 seconds (1200 × 300 = 3600 CU) Throttled requests Don’t completely depend on burst capacity… provision sufficient throughput
  • 27. What causes throttling? •  If sustained throughput goes beyond provisioned throughput per partition •  From the example before: –  Table created with 5000 RCUs, 500 WCUs –  RCUs per partition = 1666.67 –  WCUs per partition = 166.67 –  If sustained throughput > (1666 RCUs or 166 WCUs) per key or partition, DynamoDB may throttle requests •  Solution: Increase provisioned throughput
  • 28. What causes throttling? •  Non-uniform workloads –  Hot keys/hot partitions –  Very large bursts •  Dilution of throughout across partitions caused by mixing hot data with cold data –  Use a table per time period for storing time series data so WCUs and RCUs are applied to the hot data set
  • 29. Data Modeling Store data based on how you will access it!
  • 30. 1:1 relationships or key-values •  Use a table with a hash key •  Use GetItem or BatchGetItem API Example: Given a user or email, get attributes Users  Table   Hash  key   A/ributes   UserId  =  bob   Email  =  bob@gmail.com,  JoinDate  =  2011-­‐11-­‐15   UserId  =  fred   Email  =  fred@yahoo.com,  JoinDate  =  2011-­‐12-­‐01   Users-­‐Email-­‐GSI   Hash  key   A/ributes   Email  =  bob@gmail.com   UserId  =  bob,  JoinDate  =  2011-­‐11-­‐15   Email  =  fred@yahoo.com   UserId  =  fred,  JoinDate  =  2011-­‐12-­‐01  
  • 31. 1:N relationships or parent-children •  Use a table with hash and range key •  Use Query API Example: –  Given a device, find all readings between epoch X, Y Device-­‐measurements   Hash  Key   Range  key   A/ributes   DeviceId  =  1   epoch  =  5513A97C   Temperature  =  30,  pressure  =  90   DeviceId  =  1   epoch  =  5513A9DB   Temperature  =  30,  pressure  =  90  
  • 32. N:M relationships •  Use a table and GSI with hash and range key elements switched •  Use Query API Example: Given a user, find all games. Or given a game, find all users. User-­‐Games-­‐Table   Hash  Key   Range  key   UserId  =  bob   GameId  =  Game1   UserId  =  fred   GameId  =  Game2   UserId  =  bob   GameId  =  Game3   Game-­‐Users-­‐GSI   Hash  Key   Range  key   GameId  =  Game1   UserId  =  bob   GameId  =  Game2   UserId  =  fred   GameId  =  Game3   UserId  =  bob  
  • 33. Documents (JSON) •  New data types (M, L, BOOL, NULL) introduced to support JSON •  Document SDKs –  Simple programming model –  Conversion to/from JSON –  Java, JavaScript, Ruby, .NET •  Cannot index (S,N) elements of a JSON object stored in M –  They need to be modeled as top-level table attributes to be used in LSIs and GSIs Javascript DynamoDB string S number N boolean BOOL null NULL array L object M
  • 34. Rich expressions •  Projection expression –  Query/Get/Scan: ProductReviews.FiveStar[0] •  Filter expression –  Query/Scan: #V > :num (#V is a place holder for keyword VIEWS) •  Conditional expression –  Put/Update/DeleteItem: attribute_not_exists (#pr.FiveStar) •  Update expression –  UpdateItem: set Replies = Replies + :num
  • 35. Scenarios and Best Practices
  • 37. Time series tables Events_table_2015_April Event_id (Hash key) Timestamp (range key) Attribute1 …. Attribute N Events_table_2015_March Event_id (Hash key) Timestamp (range key) Attribute1 …. Attribute N Events_table_2015_Feburary Event_id (Hash key) Timestamp (range key) Attribute1 …. Attribute N Events_table_2015_January Event_id (Hash key) Timestamp (range key) Attribute1 …. Attribute N RCUs = 1000 WCUs = 100 RCUs = 10000 WCUs = 10000 RCUs = 100 WCUs = 1 RCUs = 10 WCUs = 1 Current table Older tables HotdataColddata Don’t mix hot and cold data; archive cold data to Amazon S3
  • 38. Use a table per time period •  Pre-create daily, weekly, monthly tables •  Provision required throughput for current table •  Writes go to the current table •  Turn off (or reduce) throughput for older tables Dealing with time series data
  • 40. Partition 1 2000 RCUs Partition K 2000 RCUs Partition M 2000 RCUs Partition 50 2000 RCU Scaling bottlenecks Product A Product B Shoppers ProductCatalog Table 100,000↓𝑅𝐶𝑈 /​50↓𝑃𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛𝑠      ≈𝟐𝟎𝟎𝟎     𝑅𝐶𝑈   𝑝𝑒𝑟   𝑝𝑎𝑟𝑡𝑖𝑡𝑖𝑜𝑛 SELECT Id, Description, ... FROM ProductCatalog WHERE Id="POPULAR_PRODUCT"
  • 41. RequestsPerSecond Item Primary Key Request Distribution Per Hash Key DynamoDB Requests
  • 42. Partition 1 Partition 2 ProductCatalog Table User DynamoDB User SELECT Id, Description, ... FROM ProductCatalog WHERE Id="POPULAR_PRODUCT"
  • 43. RequestsPerSecond Item Primary Key Request Distribution Per Hash Key DynamoDB Requests Cache Hits
  • 44. Messaging App Large items Filters vs. indexes M:N Modeling—inbox and outbox
  • 45. Messages Table Messages App David SELECT * FROM Messages WHERE Recipient='David' LIMIT 50 ORDER BY Date DESC Inbox SELECT * FROM Messages WHERE Sender ='David' LIMIT 50 ORDER BY Date DESC Outbox
  • 46. Recipient Date Sender Message David 2014-10-02 Bob … … 48 more messages for David … David 2014-10-03 Alice … Alice 2014-09-28 Bob … Alice 2014-10-01 Carol … Large and small attributes mixed (Many more messages) David Messages Table 50 items × 256 KB each Large message bodies Attachments SELECT * FROM Messages WHERE Recipient='David' LIMIT 50 ORDER BY Date DESC Inbox
  • 47. ​50↓𝑖𝑡𝑒𝑚𝑠 ×​256↓𝐾𝐵 ×  ​​1↓𝑅𝐶𝑈 /​4↓𝐾𝐵  ×  ​​1↓𝑟𝑒𝑎𝑑 /​2↓𝑒. 𝑐.   𝑟𝑒𝑎𝑑𝑠  =​ 𝟏 𝟔𝟎𝟎↓𝑹𝑪𝑼  Computing inbox query cost Items evaluated by query Average item size Conversion ratio Eventually consistent reads
  • 48. Recipient Date Sender Subject MsgId David 2014-10-02 Bob Hi!… afed David 2014-10-03 Alice RE: The… 3kf8 Alice 2014-09-28 Bob FW: Ok… 9d2b Alice 2014-10-01 Carol Hi!... ct7r Separate the bulk data Inbox-GSI Messages Table MsgId Body 9d2b … 3kf8 … ct7r … afed … David 1.  Query Inbox-GSI: 1 RCU 2.  BatchGetItem Messages: 1600 RCU (50 separate items at 256 KB) (50 sequential items at 128 bytes) Uniformly distributes large item reads
  • 50. Simplified writes David PutItem { MsgId: 123, Body: ..., Recipient: Steve, Sender: David, Date: 2014-10-23, ... } Inbox Global secondary index Messages Table
  • 51. Outbox Sender Outbox GSI SELECT * FROM Messages WHERE Sender ='David' LIMIT 50 ORDER BY Date DESC
  • 53. •  Reduce one-to-many item sizes •  Configure secondary index projections •  Use GSIs to model M:N relationship between sender and recipient Distribute large items Querying many large items at once InboxMessagesOutbox
  • 54. Multiplayer Online Gaming Query filters vs. composite key indexes
  • 55. GameId Date Host Opponent Status d9bl3 2014-10-02 David Alice DONE 72f49 2014-09-30 Alice Bob PENDING o2pnb 2014-10-08 Bob Carol IN_PROGRESS b932s 2014-10-03 Carol Bob PENDING ef9ca 2014-10-03 David Bob IN_PROGRESS Games Table Multiplayer online game data
  • 56. Query for incoming game requests •  DynamoDB indexes provide hash and range •  What about queries for two equalities and a range? SELECT * FROM Game WHERE Opponent='Bob‘ AND Status=‘PENDING' ORDER BY Date DESC (hash) (range) (?)
  • 57. Secondary Index Opponent Date GameId Status Host Alice 2014-10-02 d9bl3 DONE David Carol 2014-10-08 o2pnb IN_PROGRESS Bob Bob 2014-09-30 72f49 PENDING Alice Bob 2014-10-03 b932s PENDING Carol Bob 2014-10-03 ef9ca IN_PROGRESS David Approach 1: Query filter Bob
  • 58. Secondary Index Approach 1: Query filter Bob Opponent Date GameId Status Host Alice 2014-10-02 d9bl3 DONE David Carol 2014-10-08 o2pnb IN_PROGRESS Bob Bob 2014-09-30 72f49 PENDING Alice Bob 2014-10-03 b932s PENDING Carol Bob 2014-10-03 ef9ca IN_PROGRESS David SELECT * FROM Game WHERE Opponent='Bob' ORDER BY Date DESC FILTER ON Status='PENDING' (filtered out)
  • 59. Needle in a haystack Bob
  • 60. •  Send back less data “on the wire” •  Simplify application code •  Simple SQL-like expressions –  AND, OR, NOT, () Use query filter Your index isn’t entirely selective
  • 61. Approach 2: Composite key StatusDate DONE_2014-10-02 IN_PROGRESS_2014-10-08 IN_PROGRESS_2014-10-03 PENDING_2014-09-30 PENDING_2014-10-03 Status DONE IN_PROGRESS IN_PROGRESS PENDING PENDING Date 2014-10-02 2014-10-08 2014-10-03 2014-10-03 2014-09-30
  • 62. Secondary Index Approach 2: Composite key Opponent StatusDate GameId Host Alice DONE_2014-10-02 d9bl3 David Carol IN_PROGRESS_2014-10-08 o2pnb Bob Bob IN_PROGRESS_2014-10-03 ef9ca David Bob PENDING_2014-09-30 72f49 Alice Bob PENDING_2014-10-03 b932s Carol
  • 63. Opponent StatusDate GameId Host Alice DONE_2014-10-02 d9bl3 David Carol IN_PROGRESS_2014-10-08 o2pnb Bob Bob IN_PROGRESS_2014-10-03 ef9ca David Bob PENDING_2014-09-30 72f49 Alice Bob PENDING_2014-10-03 b932s Carol Secondary Index Approach 2: Composite key Bob SELECT * FROM Game WHERE Opponent='Bob' AND StatusDate BEGINS_WITH 'PENDING'
  • 64. Needle in a sorted haystack Bob
  • 65. Sparse indexes Id     (Hash)   User   Game  Score  Date   Award   1   Bob   G1   1300   2012-­‐12-­‐23   2   Bob   G1   1450   2012-­‐12-­‐23   3   Jay   G1   1600   2012-­‐12-­‐24   4   Mary   G1   2000   2012-­‐10-­‐24   Champ   5   Ryan   G2   123   2012-­‐03-­‐10   6   Jones  G2   345   2012-­‐03-­‐20   Game-scores-table Award     (Hash)   Id   User   Score   Champ   4   Mary   2000   Award-GSI Scan sparse hash GSIs
  • 66. •  Concatenate attributes to form useful secondary index keys •  Take advantage of sparse indexes Replace filter with indexes You want to optimize a query as much as possible Status + Date
  • 68. AWS Big Data Platform Overview Richard Freeman, PhD Senior Data Scientist / Architect richard.freeman@justgiving.com
  • 69. 69 We are A tech-for-good company that is Connecting the World’s Causes with People who Care DONATIONS $3bn of donations raised since launch, $576m in 2014 CHARITIES 20,000 charities on the platform USERS 23m users have made a transaction REACH Givers in 164 countries donate to causes in 12 countries DATA Billions of data points AMAZON WEB SERVICES Production environment micro-services and big data analytics, reporting and KPIs
  • 70. The Challenge •  Data sources: clickstream, logs, data warehouse, and external data sources •  Data too big and SQL queries too complex for data warehouse •  Machine Learning algorithms at scale •  Generate KPI and interactive reports New Data Science Use Cases •  High throughput •  Live view in near real-time •  Scale out •  Minimum maintenance Web Events
  • 71.
  • 72. Real Time Web Analytics with Kinesis and DynamoDB
  • 73. The Outcome • Live view on the data • Fast to query and scales out • Minimum support and maintenance • Needed a pattern to maximise throughput of temporal data DynamoDB • AWS services managed cloud services and SDKs • New pattern: Resilient and incremental data loads into many Redshift clusters in parallel • One Redshift cluster per stakeholder, e.g. business, data scientist, analysts, DBAs • Scale out and run complex queries and machine learning algorithms RAVEN platform: Scalable reporting and analytics cloud platform
  • 74. Thank you! We are hiring! Contact: Richard.freeman @justgiving.com
  • 77. Requirements for voting •  Allow each person to vote only once •  No changing votes •  Real-time aggregation •  Voter analytics, demographics
  • 79. Partition 1 1000 WCUs Partition K 1000 WCUs Partition M 1000 WCUs Partition N 1000 WCUs Votes Table Candidate A Candidate B Scaling bottlenecks Voters Provision 200,000 WCUs
  • 80. Write sharding Candidate A_2 Candidate B_1 Candidate B_2 Candidate B_3 Candidate B_5 Candidate B_4 Candidate B_7 Candidate B_6 Candidate A_1 Candidate A_3 Candidate A_4 Candidate A_7 Candidate B_8 Candidate A_6 Candidate A_8 Candidate A_5 Voter Votes Table
  • 81. Write sharding Candidate A_2 Candidate B_1 Candidate B_2 Candidate B_3 Candidate B_5 Candidate B_4 Candidate B_7 Candidate B_6 Candidate A_1 Candidate A_3 Candidate A_4 Candidate A_7 Candidate B_8 UpdateItem: “CandidateA_” + rand(0, 200) ADD 1 to Votes Candidate A_6 Candidate A_8 Candidate A_5 Voter Votes Table
  • 82. Votes Table Shard aggregation Candidate A_2 Candidate B_1 Candidate B_2 Candidate B_3 Candidate B_5 Candidate B_4 Candidate B_7 Candidate B_6 Candidate A_1 Candidate A_3 Candidate A_4 Candidate A_5 Candidate A_6 Candidate A_8 Candidate A_7 Candidate B_8 Periodic Process Candidate A Total: 2.5M 1. Sum 2. Store Voter
  • 83. •  Trade off read cost for write scalability •  Consider throughput per hash key and per partition Shard write-heavy hash keys Your write workload is not horizontally scalable
  • 84. Correctness in voting UserId Candidate Date Alice A 2013-10-02 Bob B 2013-10-02 Eve B 2013-10-02 Chuck A 2013-10-02 RawVotes Table Segment Votes A_1 23 B_2 12 B_1 14 A_2 25 AggregateVotes Table Voter 1. Record vote and de-dupe; retry 2. Increment candidate counter
  • 85. Correctness in aggregation? UserId Candidate Date Alice A 2013-10-02 Bob B 2013-10-02 Eve B 2013-10-02 Chuck A 2013-10-02 RawVotes Table Segment Votes A_1 23 B_2 12 B_1 14 A_2 25 AggregateVotes Table Voter
  • 87. •  Stream of updates to a table •  Asynchronous •  Exactly once •  Strictly ordered –  Per item •  Highly durable •  Scale with table •  24-hour lifetime •  Sub-second latency DynamoDB Streams
  • 88. View Type Destination Old image—before update Name = John, Destination = Mars New image—after update Name = John, Destination = Pluto Old and new images Name = John, Destination = Mars Name = John, Destination = Pluto Keys only Name = John View types UpdateItem (Name = John, Destination = Pluto)
  • 89. Stream Table Partition 1 Partition 2 Partition 3 Partition 4 Partition 5 Table Shard 1 Shard 2 Shard 3 Shard 4 KCL Worker KCL Worker KCL Worker KCL Worker Amazon Kinesis Client Library Application DynamoDB Client Application Updates DynamoDB Streams and Amazon Kinesis Client Library
  • 90. DynamoDB Streams Open Source Cross- Region Replication Library Asia Pacific (Sydney) EU (Ireland) Replica US East (N. Virginia) Cross-region replication
  • 91. DynamoDB Streams and AWS Lambda
  • 92. Real-time voting architecture (improved) AggregateVotes Table Amazon Redshift Amazon EMR Your Amazon Kinesis– Enabled App Voters RawVotes TableVoting App RawVotes DynamoDB Stream
  • 93. Real-time voting architecture AggregateVotes Table Amazon Redshift Amazon EMR Your Amazon Kinesis- Enabled App Voters RawVotes TableVoting App RawVotes DynamoDB Stream
  • 94. Real-time voting architecture AggregateVotes Table Amazon Redshift Amazon EMR Your Amazon Kinesis- Enabled app Voters RawVotes TableVoting App RawVotes DynamoDB Stream
  • 95. Real-time voting architecture AggregateVotes Table Amazon Redshift Amazon EMR Your Amazon Kinesis– Enabled App Voters RawVotes TableVoting app RawVotes DynamoDB Stream
  • 96. Real-time voting architecture AggregateVotes Table Amazon Redshift Amazon EMR Your Amazon Kinesis– Enabled App Voters RawVotes TableVoting app RawVotes DynamoDB Stream
  • 97. Analytics with DynamoDB Streams •  Collect and de-dupe data in DynamoDB •  Aggregate data in-memory and flush periodically Performing real-time aggregation and analytics
  • 100. LONDON