Redis Hash Internal Encoding: Ziplist vs Hashtable – Performance Analysis and Optimization
The incident showed that Redis hashes encoded as ziplist incur O(N) HEXISTS latency, causing high CPU on hot keys, while hashtable‑encoded hashes remain O(1); adjusting hash‑max‑ziplist settings or redesigning hot‑key patterns can convert to faster, though more memory‑hungry, hashtable encoding.