Hacker News new | ask | show | jobs
by pushcx 106 days ago
TypeID is similar, though it uses the UUIDv7 directly: https://github.com/jetify-com/typeid Maybe the formalization would be interesting to you.

It doesn't have a checksum, though, that seems like an improvement that's worth a few bytes.

1 comments

Thanks! I didn't know about TypeID (and I thought I'd searched thoroughly).

The formalization interests me. Shame they shifted the UUID 2 bits right. Otherwise our implementations would be almost compatible (only the last 2 bits of the 26th character + the last 3 characters would differ). In my next clean codebase, I may use TypeID and append a 15-bit checksum.