Add randomness to GenIds (IMPORT) #3
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Add a unit test for GenIds which generates many (500? 1000? benchmark will help with determination) in a loop and tests for duplicates
Write a second implementation, which adds some randomness (two bytes?) before hashing
Unit test that version
Benchmark both
Add randomness until we can reasonably guarantee generation Ids with no dupes, based on GenId runtime as reported by benchmark (plus a pad, of course, as machines vary)