2 ms·
Isn't this the reason UUIDs were invented?
by stingraycharles 13y ago
Isn't this the reason UUIDs were invented?
- lostcolony 13y agoNot exactly. UUIDs are for uniqueness, but don't imply order. Timestamps imply order, but not necessarily uniqueness. Sometimes you want both. Some languages give you mechanisms to guarantee an increasing timestamp (Erlang's erlang:now(), for instance) for that purpose. Now, if this is actually appending just random data, rather than an incrementing counter, you still are guaranteeing uniqueness (well, a reasonable guarantee of probably uniqueness), and have order to a specific coarseness, but beyond that all bets are off. My guess is that it's to imply an absolute ordering, but once you're sub-millisecond assume that it doesn't really matter if the order is accurate.