4 ms·
They can be generated anywhere, otherwise they wouldn't be universally unique.
by jayknight 3y ago
They can be generated anywhere, otherwise they wouldn't be universally unique.
- jamil7 3y agoI'm not asking about the uniqueness but about ordering across different clients.
- roenxi 3y agoThere is probably an impossibility theory somewhere for two clients generating ordered ID without communicating with each other. What if one client was travelling near the speed of light for example? It isn't obvious what order would be correct since the two clients would have wildly different perceptions of time.
- ahoka 3y agoYes, it’s impossible in theory. Same as the two generals problem, if I’m not mistaken.
- sibit 3y agoIf they're generated on the client you would need to keep clock drift[0] in mind since the leading bits are time based. [0]: https://youtu.be/mAyW-4LeXZo https://youtu.be/mAyW-4LeXZo (Clock Synchronization in Distributed Systems by Martin Kleppmann)