3 ms·
What about spanner specifically benefits from random ids over sequential ones?
by bddicken 6mo ago
What about spanner specifically benefits from random ids over sequential ones?
- traderj0e 6mo agoI'm not an expert on Spanner, supposedly it's due to hotspotting. Your data is partitioned by primary key, and if you make that sequential, all new writes will hit the same master. https://docs.cloud.google.com/spanner/docs/schema-and-data-model#choose_a_primary_key https://docs.cloud.google.com/spanner/docs/schema-and-data-m... explicitly recommends a uuid4 or some other options That's another thing, some say to use uuid7 for sharded DBs, but this is a serious counterexample.