Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Scale fearlessly with Amazon
DynamoDB...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
25x increase
Requestsperhour
900 writ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Objectives
Use DynamoDB more effectiv...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Related sessions (online)
DAT201 – Wh...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Database capacity planning
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Vertical scaling
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Scaling NoSQL DBsHorizontal scaling
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
The uneven access problem common to N...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Just design for uniform access to you...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
DynamoDB adapts to your application, ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Core functions of adaptive capacity
D...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1.p1
Table1 Table2 Table3
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
T1
Server 1
p.A
Storage scaling
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 2
A B
Storage scal...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 2
A B
Storage scal...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 2 Server 3
A B C
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 2 Server 3
A B C
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 4 Server 2 Server ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Scenario: Census application
Statisti...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
What you didn’t realize…
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
Table
Server 2 Server 3 Serv...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Dynamic partitioning
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Dynamic partitioning
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1 Server 2 Server 3 Server 4
D...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 2 Server 3 Server 4
Dynamic pa...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 2 Server 3 Server 4
Dynamic pa...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 7 Server 3 Server 4
Dynamic pa...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Summary of dynamic partitioning
Dynam...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Table
(items)
Per-item limits:
1,000 ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
DynamoDB Key Diagnostics Library
Grap...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1
Server 4 Server 2 Server ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1 Server 4 Server 2 Server 3
D...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Adaptive capacity governance in 2018
...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
New in 2019 – Instant adaptive capaci...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1.p1
Table1 Table2 Table3
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1.p1
Table1
Table2
Table3
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1.p1
Table1
Table2
Table3
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Server 1
T1.p1
Table1
Table2
Table3
S...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Instant adaptive capacity
DynamoDB lo...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Get massive scalability and consisten...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
DynamoDB on-demand
Features
• No capa...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
What are the maximum scaling
capabili...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
On-demand scaling properties
Minimum ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
DynamoDB request
rate
Maximum
through...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
“Up to twice your previous peak”
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Dynamic partitioning
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Instant high throughput
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Things to keep in mind
Initial doubli...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
On-demand mode use case – Infrequent ...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Business impact
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
When to use provisioned vs. on-demand...
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
DynamoDB adaptive capacity at a glanc...
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
Key takeaways
DynamoDB adapts to your...
Thank you!
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Kai Zhao
kazh@amazon.com
S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Upcoming SlideShare
Loading in …5
×

Scale fearlessly with Amazon DynamoDB adaptive capacity - ADB302 - Santa Clara AWS Summit

1,125 views

Published on

Amazon DynamoDB is a NoSQL database service that delivers single-digit millisecond performance at any scale. In this session, learn how to scale your database by 10x without breaking a sweat (or the bank). We dive deep into how DynamoDB shards your data and optimizes database performance on your behalf. Learn the latest in adaptive capacity technology, when to use on-demand read/write capacity mode, and the other ways in which DynamoDB adapts to your workload instead of requiring you to adapt to a database.

  • DOWNLOAD FULL BOOKS, INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

Scale fearlessly with Amazon DynamoDB adaptive capacity - ADB302 - Santa Clara AWS Summit

  1. 1. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Scale fearlessly with Amazon DynamoDB adaptive capacity Kai Zhao Senior Product Manager Amazon DynamoDB A D B 3 0 2
  2. 2. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T 25x increase Requestsperhour 900 writes/sec 25,000 writes/sec
  3. 3. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Objectives Use DynamoDB more effectively How DynamoDB scaling really works, from 1 RPS to millions of RPS What’s new in adaptive capacity When to use provisioned mode vs. on-demand mode
  4. 4. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Related sessions (online) DAT201 – What’s New For Amazon DynamoDB Tony Petrossian, Jeff Wierer DAT321 – Amazon DynamoDB Under the Hood Jaso Sorensen DAT401 – Advanced Design Patterns for DynamoDB Rick Houlihan
  5. 5. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  6. 6. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Database capacity planning
  7. 7. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Vertical scaling
  8. 8. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T
  9. 9. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Scaling NoSQL DBsHorizontal scaling
  10. 10. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T The uneven access problem common to NoSQL across data and time
  11. 11. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Just design for uniform access to your data, right? Can be quite difficult in practice Most NoSQL databases aren’t very forgiving If your database isn’t flexible, you must handle more in your application How does DynamoDB solve this for customers?
  12. 12. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  13. 13. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T DynamoDB adapts to your application, not vice versa
  14. 14. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Core functions of adaptive capacity Dynamic partitioning Throughput governance
  15. 15. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  16. 16. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1.p1 Table1 Table2 Table3 Server N T1.p2 Behind the scenes…
  17. 17. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T T1 Server 1 p.A Storage scaling
  18. 18. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 2 A B Storage scaling
  19. 19. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 2 A B Storage scaling
  20. 20. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 2 Server 3 A B C Storage scaling
  21. 21. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 2 Server 3 A B C Storage scaling
  22. 22. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 4 Server 2 Server 3 A D B C Storage scaling
  23. 23. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Scenario: Census application Statistics Canada (Canada's national statistical agency) hires you to build an online census application. You choose DynamoDB with the following key schema: Partition key: province Sort key: id
  24. 24. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T What you didn’t realize…
  25. 25. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  26. 26. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 Table Server 2 Server 3 Server 4 Census traffic 64% Ontario, Quebec, Newfoundland, and Labrador Prince Edward Island British Columbia, Alberta, Saskatchewan Manitoba, Nova Scotia, Northwest Territories New Brunswick, Nunavut, Yukon 28% 6% 2%
  27. 27. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Dynamic partitioning
  28. 28. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Dynamic partitioning
  29. 29. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 Server 2 Server 3 Server 4 Dynamic partitioning – behind the scenes Ontario, Quebec, Newfoundland, and Labrador Prince Edward Island British Columbia, Alberta, Saskatchewan Manitoba, Nova Scotia, Northwest Territories New Brunswick, Nunavut, Yukon
  30. 30. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 2 Server 3 Server 4 Dynamic partitioning – behind the scenes British Columbia, Alberta, Saskatchewan Manitoba, Nova Scotia, Northwest Territories New Brunswick, Nunavut, Yukon Server 1 Ontario Server 5 Quebec, Newfoundland and Labrador, Prince Edward Island
  31. 31. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 2 Server 3 Server 4 Dynamic partitioning – behind the scenes British Columbia, Alberta, Saskatchewan Manitoba, Nova Scotia, Northwest Territories New Brunswick, Nunavut, Yukon Server 1 Ontario.A Server 5 Quebec, Newfoundland and Labrador, Prince Edward Island Server 6 Ontario.B
  32. 32. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 7 Server 3 Server 4 Dynamic partitioning – behind the scenes Alberta, Saskatchewan Manitoba, Nova Scotia, Northwest Territories New Brunswick, Nunavut, Yukon Server 1 Ontario.A Server 5 Quebec, Newfoundland and Labrador, Prince Edward Island Server 6 Ontario.B Server 2 British Columbia
  33. 33. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Summary of dynamic partitioning DynamoDB adapts to your application, not vice versa Automatic partitioning to equalize storage and throughput Throughput-based partitioning currently available for on-demand mode
  34. 34. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Table (items) Per-item limits: 1,000 writes per sec 6,000 reads per sec (EC)
  35. 35. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T DynamoDB Key Diagnostics Library Graphs of frequently accessed items Lightweight wrapper around DynamoDB SDK AWS CloudFormation template
  36. 36. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  37. 37. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1 Server 4 Server 2 Server 3 A D B C Adaptive capacity governance in 2018 A
  38. 38. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 Server 4 Server 2 Server 3 D B C Adaptive capacity governance in 2018 AA T1
  39. 39. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Adaptive capacity governance in 2018 Pros: Accommodates imbalanced workloads Helps you be more efficient (provision fewer WCUs and RCUs) Cons: Reactive process with 5–30 minute response
  40. 40. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T New in 2019 – Instant adaptive capacity No more response time Partitions respond instantly in response to changing traffic
  41. 41. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1.p1 Table1 Table2 Table3 Server N T1.p2 Instant adaptive capacity – How it works
  42. 42. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1.p1 Table1 Table2 Table3 Server N T1.p2 Instant adaptive capacity – How it works
  43. 43. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1.p1 Table1 Table2 Table3 Server N T1.p2 Instant adaptive capacity – How it works
  44. 44. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Server 1 T1.p1 Table1 Table2 Table3 Server N T1.p2 Instant adaptive capacity – How it works
  45. 45. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Instant adaptive capacity DynamoDB looks at what your table can do, not what partitions can do. Key benefits: • Instantly accommodates imbalanced workloads • Sustains imbalanced workloads indefinitely • Helps you reduce your DynamoDB bill • On by default, no extra cost
  46. 46. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Get massive scalability and consistent performance without worrying about partitions and uneven access patterns
  47. 47. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  48. 48. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T DynamoDB on-demand Features • No capacity planning, provisioning, or reservations—simply make API calls • Pay only for the reads and writes you perform Key benefits • Eliminates tradeoffs of overprovisioning or underprovisioning • Instantly accommodates your workload as traffic ramps up or down
  49. 49. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T What are the maximum scaling capabilities of on-demand mode?
  50. 50. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T On-demand scaling properties Minimum throughput • Up to 4,000 write request units (WRU): 4,000 writes per second • Up to 12,000 read request units (RRU): 24,000 EC reads per second • Any linear combination of the two Maximum throughput • Unlimited! Pay per request: use nothing, pay nothing
  51. 51. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T DynamoDB request rate Maximum throughput “Up to twice your previous peak”
  52. 52. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T “Up to twice your previous peak”
  53. 53. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Dynamic partitioning
  54. 54. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Instant high throughput
  55. 55. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Things to keep in mind Initial doubling takes up to 30 minutes Subsequent traffic scales instantly Continuously monitored • No need to achieve 2x previous peak to get more throughput • Gracefully accommodates growth without throttling
  56. 56. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T On-demand mode use case – Infrequent workloads
  57. 57. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Business impact
  58. 58. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T When to use provisioned vs. on-demand Use provisioned mode for: • Steady workloads • Gradual ramps • Events with known traffic • Ongoing monitoring Use on-demand mode for: • Unpredictable workloads • Frequently idle workloads • Events with unknown traffic • “Set it and forget it” Consider your tolerance for operational overhead and overprovisioning
  59. 59. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  60. 60. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T DynamoDB adaptive capacity at a glance Provisioned Mode On-demand mode Governance Instant (provisioned capacity) Instant (account limits) Default limits (increasable) 40,000 WCU, 40,000 RCU 40,000 WRU, 40,000 RRU Dynamic partitioning (storage) Automatic Automatic Dynamic partitioning (throughput) Not available yet Automatic Key Diagnostics Library Supported Supported
  61. 61. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.S U M M I T Key takeaways DynamoDB adapts to your application, not vice versa Scale up or down at will, even with skewed data access patterrns Focus on application traffic to your table and items, not on partitions Provisioned mode for gradual ramps, on-demand mode for spikes
  62. 62. Thank you! S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Kai Zhao kazh@amazon.com
  63. 63. S U M M I T © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.

×