Breaking News: Grepper is joining You.com. Read the official announcement!
Check it out

Consistent prefix reads#

Sumit Rawal answered on June 23, 2023 Popularity 3/10 Helpfulness 1/10

Contents


More Related Answers


Consistent prefix reads#

0

Imagine a scenario where the North Korean dictator tweets “Successful missile tests!” and in response POTUS tweets “Sanctions imposed on North Korea”. The timeline of tweets will reveal that sanctions were imposed by the US after North Korea test-fired missiles, but if we flip the order of the tweets, users can comprehend that North Korea test-fired missiles after the US imposed sanctions.

Taking this example a step further, we can see there’s a casual relationship between the two tweets which translate into writes on the backend database. It could potentially happen that the tweet from the North Korean dictator is replicated on a set of servers in Asia while the one from POTUS is replicated on a set of servers in North America. Eventually, the tweets get copied over to all the servers but for a short period of time the regional servers may not have cross-continental tweets. In such a scenario, a user retrieving tweets in Brazil may connect to the North American servers and see the tweet from POTUS first and then see the tweet from North Korea, thinking that North Korea test-fired missiles in retaliation to US sanctions. Because of the lag in replicating tweets globally, the order of the writes is altered or that their causal relationship is inverted.

The consistent prefix reads guarantee says that if a sequence of writes happen in a certain order then the writes are served to the reader in the same order. This is especially important for distributed databases that have different partitions and there’s no global ordering of writes. One mitigation is to direct all the related writes to the same partition. Dependency tracking software is used in situations where writing to the same partition isn’t possible.

Popularity 3/10 Helpfulness 1/10 Language whatever
Source: Grepper
Link to this answer
Share Copy Link
Contributed on Jun 23 2023
Sumit Rawal
0 Answers  Avg Quality 2/10


X

Continue with Google

By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
X
Grepper Account Login Required

Oops, You will need to install Grepper and log-in to perform this action.