Use HMGET to fetch multiple keys from same hash. With HMGET, only one command needs to be sent to Redis.
Replaces MULTI/EXEC with PIPELINE. Pipeline is slightly faster but does not guarantee atomicity of operations. This shouldn't cause any additional concurrency issues as the commands emitted in add do not have any dependency of each other and all clients should emit the same commands.
Use
HMGET
to fetch multiple keys from same hash. WithHMGET
, only one command needs to be sent to Redis.Replaces MULTI/EXEC with PIPELINE. Pipeline is slightly faster but does not guarantee atomicity of operations. This shouldn't cause any additional concurrency issues as the commands emitted in add do not have any dependency of each other and all clients should emit the same commands.