I was going to post about "use a UUID", but I was surprised to learn that no UUID uses both timestamp + a random component. You can either get fully random with UUID4, or have a time + MAC based UUID with UUID1. Strange, I would have thought there would exist a UUID that uses time + random to minimize collisions like described in the post.
Ksuid may be what you want. Pretty much time sortable uuid.
Go implementation: https://github.com/segmentio/ksuid