A company uses Amazon DynamoDB for a gaming application. The table has a partition key of 'user_id' and a sort key of 'game_timestamp'. The application frequently queries by 'user_id' and filters by 'game_timestamp' within a specific date range. The queries are slow. The table has a global secondary index (GSI) on 'game_timestamp'. What is the most likely cause of the slow queries?
If a few 'user_id' values are accessed frequently, they create hot partitions, slowing queries.
Why this answer
Option B is correct because querying by 'user_id' using the base table is efficient, but if the GSI is being used for queries that filter by 'game_timestamp' without the partition key, the GSI may not be designed optimally. However, the stem says queries are by 'user_id' and filter by 'game_timestamp' – that should use the base table. Option A is not likely because sort key filtering is efficient.
Option C (hot partition) is possible if 'user_id' distribution is skewed. Option D (GSI write capacity) doesn't affect reads. The most likely cause is a hot partition due to uneven 'user_id' distribution.