What is Redis pipelining?
Answer
Redis pipelining allows a client to send multiple commands to the server without waiting for the reply to each one, then read all replies in one batch. Without pipelining, each command incurs a round-trip network latency (RTT). With pipelining, you send N commands in one network trip and receive N replies at once, dramatically reducing the total time when performing many operations. Pipelining is a client-side optimization — the Redis server still processes commands one by one. For example, inserting 1,000 cache keys individually might take 1,000 × 0.5ms = 500ms in latency alone; pipelining reduces this to approximately one RTT regardless of batch size. All major Redis client libraries support pipelining.
Previous
What are common real-world use cases for Redis?
Next
What does it mean that Redis operations are atomic?