CLIENT PAUSE
Since 1.1.0Server
Syntax
CLIENT PAUSE timeout [WRITE | ALL]Holds clients' commands for timeout milliseconds, or until CLIENT UNPAUSE.
ALL, the default: every command butCLIENT UNPAUSE.WRITE: anything that may write, includingPFCOUNT,PUBLISH, scripts not declaredno-writes, and anEXECthat contains any of these. Reads go on.
A pause given during another keeps the more restrictive of the two. While writes are paused, nothing expires, as in Redis: a read takes a key whose time has passed as gone, but it is deleted and counted only once the pause is over. The same holds during a cluster slot handoff and a manual failover.
Examples
client 1> CLIENT PAUSE 300 WRITE
OK
client 2> GET user:1
"Grace"
client 2> SET p 1 (waits about 300 ms)
OK