Hi redis developers, I have some questions regarding bitmap race condition
Scenario,
Let's say I have a bitmap key called mybit and this mybit will be modified by different consumer A,B,C and each consumer will modify certain offset value
mybit -> consumer A modify offset 0
-> consumer B modify offset 1
-> consumer C modify offset 2
Consumers will not get the value from this mybit key only to set the value 1 in specific offset. I was wondering is there might be a chance that this mybit would encounter race condition? I assuming the race condition would happen if each SETBIT command will get the whole key value and then set the bit in offset and return. Somehow the slave node is not synced will this cause race condition.
If the core impl is to set the bit in specific offset without getting all the value for this key, I assuming there won't have race condition. But seeing the document I cannot find related material which bothers me right now....
Redis developers please help me on that~ much thanks!
Comment From: sundb
In Redis, commands is always processing in the main thread, so all commands do not raise race conditions.