Q3 Redis Domain 2 · 25–30% of exam

A Python application uses the redis-py library. Which method correctly retrieves multiple keys in a single network round trip?

  1. A Calling get() in a loop
  2. B Using pipeline() to batch GET commands
  3. C Using mget([key1, key2, ...]) (correct answer)
  4. D Using asyncio with separate get() calls

Shortcut: mget fetches multiple keys in a single command and round trip. pipeline() batches arbitrary commands, also reducing round trips. mget is the most idiomatic for bulk key retrieval.