DSA 5600 – NoSQL Database
Systems
Section 5: Amazon DynamoDB
Instructor: Yutong Zhao
1. Overview
2
What is Amazon DynamoDB?
3
Core Features of DynamoDB
4
How Amazon Uses DynamoDB for Scalability
Amazon’s Shopping Cart System:
• Amazon handles millions of transactions per second, especially
during peak shopping seasons.
• A relational database would struggle with this level of scale and
require complex sharding.
• DynamoDB solves this problem by providing low-latency, highly
available, and infinitely scalable storage.
5
When to Use DynamoDB?
6
Understanding Tables, Items, and Attributes
7
Primary Key Design (Partition & Sort
Keys)
8
2. Data Types
9
Data Types in DynamoDB
1
Data Type Example
1
Reading Data – GetItem, Query & Scan
1
Updating & Deleting Data
1
3. Performance
14
Secondary Indexes – Why &
When?
1
Global Secondary Indexes (GSI)
1
Local Secondary Indexes (LSI)
1
4. Data Types?
18
DynamoDB Streams
1
Transactions in DynamoDB
2
Time-to-Live (TTL) for Automatic Expiration
2
DynamoDB Accelerator (DAX) for Caching
2
On-Demand vs. Provisioned Capacity
2
5. Security Best Practices in DynamoDB
24
Security Best Practices in
DynamoDB
2
Monitoring &
Logging
2
Performance Optimization Strategies
2
Cost Optimization Strategies
2
6. Best Practices in DynamoDB
29
Example: Using DynamoDB for Gaming
Applications
3
DynamoDB for Serverless Applications
3
IoT & Real-Time Data Processing
3
Gaming & Leaderboards
3
DynamoDB in AI/ML Workloads
3
7. Final Review
35
Final Review
• NoSQL, Serverless, and Fully Managed
• Partition & Sort Keys – Efficient Data Modeling
• Querying & Indexing – Query Over Scan
• Performance Optimization – Auto-Scaling & Caching
• Transactions & ACID Compliance
• DynamoDB Streams – Event-Driven Processing
• Security & Access Control – IAM & Encryption
• Cost Optimization – Pay for What You Use
3
3