by ryanto · 4y ago · 0 comments
From the blog post it says read-only replicas are created close to users and kept up to date with the latest data.
- How should I think about this in terms of CAP? If there's a write and I query a replica what happens?
- How are writes handled? Do they go to a single location or are they handled by various locations?
I'm excited to try this. It's so cool to see databases being distributed "on CDNs" for lack of a better term.
> Embedded compute
> But we're going further. With D1, it will be possible to define a chunk of your Worker code that runs directly next to the database, giving you total control and maximum performance — each request first hits your Worker near your users, but depending on the operation, can hand off to another Worker deployed alongside a replica or your primary D1 instance to complete its work.