3 ms·
What will really be nice is when UUID V7 has wide support, because in many ways it is the best of all possible worlds: 1. The UUIDs are generated in increasing
by hn_throwaway_99 5y ago
What will really be nice is when UUID V7 has wide support, because in many ways it is the best of all possible worlds:
1. The UUIDs are generated in increasing order, so none of the b-tree issues others have mentioned with fully random UUIDs.
2. They're true UUIDs, so migrating between DBs is easy, ensuring uniqueness across DBs is easy, etc.
3. They also have the benefit of having a significant amount of randomness, so if you have a bug that doesn't do an appropriate access check somewhere they are more resistant to someone trying to guess the ID from a previous one.