Re:Universally Unique Lexicographically Sortable Identifier ...
by tsenart on Tuesday December 06, 2016 @01:01PM
(#13116746)
Yes if you use a good source of entropy. In Go, the easiest and most secure is the `crypto/rand.Reader`. But it's also slow. If you don't need the security properties, an instance of `math/rand.Rand` should suffice. Otherwise, you can implement your own. It's just an io.Reader!
[ Parent
| on HN ]
Re:Universally Unique Lexicographically Sortable Identifier ...
by Freak_NL on Tuesday December 06, 2016 @03:57PM
(#13118274)
Doesn't that mean that it will usually — but not guaranteed always — be unique? That is, won't there always be a (minute and negligible depending on the intended use) chance of collision?