Challenge - 5 Problems
DynamoDB Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
❓ Configuration
intermediate2:00remaining
DynamoDB Table Partition Key Type
You want to create a DynamoDB table with a partition key named CustomerId that stores string values. Which option correctly defines the partition key attribute in the AWS CLI command?
Attempts:
2 left
💡 Hint
The partition key type must match the data type you plan to store. 'S' stands for string.
✗ Incorrect
DynamoDB attribute types include 'S' for string, 'N' for number, and 'B' for binary. 'BOOL' is not a valid attribute type for keys. Since CustomerId stores strings, 'S' is correct.
❓ Architecture
intermediate2:00remaining
Choosing a Sort Key for Efficient Queries
You are designing a DynamoDB table to store orders. Each order has a unique OrderId and a timestamp when it was placed. You want to efficiently query all orders for a customer sorted by time. Which key schema is best?
Attempts:
2 left
💡 Hint
Think about how to group orders by customer and sort them by time.
✗ Incorrect
Using CustomerId as partition key groups all orders per customer. Adding OrderTimestamp as sort key allows sorting orders by time within each customer group.
❓ security
advanced2:30remaining
IAM Policy for DynamoDB Table Access
You want to create an IAM policy that allows read-only access to a DynamoDB table named Orders. Which policy statement correctly grants this permission?
Attempts:
2 left
💡 Hint
Read-only actions include GetItem, Query, and Scan.
✗ Incorrect
To allow read-only access, the policy must allow GetItem, Query, and Scan actions. PutItem, UpdateItem, and DeleteItem are write actions. Deny effect blocks access.
❓ service_behavior
advanced2:30remaining
DynamoDB Provisioned Throughput Behavior
You create a DynamoDB table with provisioned throughput of 5 read capacity units and 5 write capacity units. What happens if your application suddenly tries to perform 20 writes per second?
Attempts:
2 left
💡 Hint
Provisioned throughput limits the number of reads and writes per second.
✗ Incorrect
If the application exceeds provisioned capacity, DynamoDB throttles excess requests and returns errors. It does not auto-scale unless auto-scaling is configured.
✅ Best Practice
expert3:00remaining
Designing a DynamoDB Table for High Write Throughput
You expect a very high number of writes per second to your DynamoDB table. Which design choice helps avoid hot partitions and ensures even write distribution?
Attempts:
2 left
💡 Hint
Think about how DynamoDB partitions data and distributes load.
✗ Incorrect
DynamoDB partitions data by partition key. High cardinality keys spread writes across partitions. Adding randomness helps avoid hot spots. Single fixed keys cause hot partitions.