You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
so, you think it's recommended to have 'short-id' like my database id(uniqueness,primary key) generator, with no collision or duplicates in some future.
This is indeed a problem, for now, the epoch is set so that timestamp minus epoch encodes to a 7-byte string, and collisions might happen when the encoded time delta bumps to 8-byte. Fortunately, it will take more than 8 years to see this happen, assuming version is never updated.
From what I understand of the code, the generation algorithm works by taking the following data in order and encoding it:
This creates a possibility of a collision between the following, assuming that the random numbers line up correctly:
a
and timestampbcde
bcdea
The text was updated successfully, but these errors were encountered: