5 ms·
The referential integrity piece (otherwise known as Foreign Keys) will not be addressed and is a limitation - some might say feature - of Vitess. They wrote a p
by epberry 5y ago
The referential integrity piece (otherwise known as Foreign Keys) will not be addressed and is a limitation - some might say feature - of Vitess. They wrote a pretty good piece about it here, https://docs.planetscale.com/tutorials/operating-without-foreign-keys https://docs.planetscale.com/tutorials/operating-without-for...
- mooreds 5y agoThanks, that looks pretty useful. To me, this means that planetscale (and vitess) immediately become less useful for a large class of applications: existing apps that use an RDBMS that you want to scale. Because most existing apps will expect FKs. I haven't tested my employer's application (which has FKs) to see what will happen, but I doubt it will be smooth sailing. But there's probably plenty of greenfield development where teams would prefer to stick with standards like SQL rather than a proprietary noSQL language, and that seems like a great fit for this solution.
- jeffbee 5y agoThere is not and will never be a solution to the problem of horizontally scaling an application and database designed jointly for a single-box ACID RDBMS. You have to compromise something to get the scaling.
- pier25 5y agoWhat is the compromise of Cockroach DB?
- romero-jk 5y agoHeavy toll on performance and is not really postgres. For the same workload pg can be up to 30x faster or more than cockroach. At some point of course, pg won't be able to keep up and the horizontal scaling of crdb will beat it.
- AYBABTME 5y agoI believe they use some statistical analysis and declared locality tags (from config) to group related cells of data on the same nodes and regions, but I don't know how effective that proves. Pure performance isn't a strong suit of CRDB as far as I can tell, but sometimes that works fine, and it does scale well horizontally.
- jpgvm 5y agoDepends on your definition of horizontally scaling and the inherent size limitations you would be willing to accept. CitusDB for example handles this by allowing FKeys between tables that share the same partition key. However it's also not -as- scalable as Vitess or as georeplication friendly but for many uses that need "more than a single box" is probably enough scalability.
- DeathArrow 5y agoWhat about CockroachDB and YugabyteDB?
- spookthesunset 5y ago> You have to compromise something to get the scaling. And the reason why is basically “physics”. The speed of light is pretty damn slow all things considered. Until we find ways to make all the servers in the cluster have latency measured in something like picoseconds, something is gonna have to give.
- deleted 5y ago[deleted]
- deleted 5y ago[deleted]
- mcronce 5y agoIt's not entirely accurate to say that Vitess "doesn't have" foreign keys. It doesn't enforce FK constraints cross-shard, but it can use FKs to group referential data together within a shard, and the MySQL backing that shard can enforce FK constraints.