Re: Sequential UUID Generation - Mailing list pgsql-hackers

From Sehrope Sarkuni
Subject Re: Sequential UUID Generation
Date
Msg-id CAH7T-aoi7ufZ2KnFbeJgVg4iSY5q52t5vSd_sXXwdkTvWdAtUg@mail.gmail.com
Whole thread Raw
In response to Re: Sequential UUID Generation  (Adam Brusselback <adambrusselback@gmail.com>)
Responses Re: Sequential UUID Generation  (Uday Bhaskar V <uday.bhaskar579@gmail.com>)
List pgsql-hackers
I came across a project for time based UUID ("tuid") a little while back: https://github.com/tanglebones/pg_tuid

I haven't used in production but skimmed through the code a bit out of technical curiosity. It handles some of the expected edge cases for backwards clock drift and concurrent generation.

The repo includes a PG extension and sample app code for generating tuids in a couple languages as well as a pure-SQL one (though that one uses random() rather than get_random_bytes() so I'd consider it more of an proof of concept).

Regards,
-- Sehrope Sarkuni
Founder & CEO | JackDB, Inc. | https://www.jackdb.com/

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Super PathKeys (Allowing sort order through precision loss functions)
Next
From: Tom Lane
Date:
Subject: Re: Lambda expressions (was Re: BUG #15471)