a redis lock implementation.