News for hackers. Stuff that matters.
Re:UUIDs are popular, but bad for performance (2019) by staticassertion on Saturday January 08, 2022 @12:30PM (#29853872)
It's going to depend on the database. This article is primarily focused on InnoDB and goes over the read/write locality issues with a uuid.

That isn't always going to matter (or can be a very good thing). For a KV store like dynamodb a uuid is a great key because it'll distribute nicely across your shards.

It also depends a lot on your query patterns. If you have a uuid primary key but you're partitioning by some other value you may end up significantly reducing the number of pages you have to look through.

There are no comments on this comment yet.