What every developer should know about database consistency
Imagine assigning some value to a variable, reading it back immediately after, and finding out that somehow the write had no effect at all - madness!
x = 42 assert(x == 42) # throws exception This is precisely what can happen when you are using a distributed data store with weak consistency guarantees. “But wait, aren’t databases supposed to take care of consistency issues for me?” I hear you ask. Whether an update becomes visible sooner rather than later depends on the guarantees offered by the database.
Roberto's blog