12/26/2023 0 Comments Cmake boostIn order to deal with a distributed system correctly, the cache and the database need to be aware of each other. Too many systems approach that in an ad-hoc way, leading to the idea that cache invalidation is uniquely hard.- Marc Brooker June 9, 2022 That's inherently a difficult problem, because it requires very clear thinking about that balance between the desired system properties and the costs of coordination. Postgres doesn't know the first client cached any data with its earlier query, etc. another client can come and mutate Postgres underneath without the first client knowing. If one runs a query against Postgres, and stores the data locally on its client cache, without the database knowing, it's obvious that invalidating the local client cache can't always be done correctly. Too many systems approach cache in an ad-hoc way, without realizing they are dealing with a distributed system, leading to the idea that figuring out when to invalidate cache is uniquely hard. Since you are dealing with a distributed system, we need to be clear about the expected state/knowledge distribution. When you are using cache, by definition, you are dealing with a distributed system – there is the cache, and the source of truth.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |