Re: What is a typical precision of gettimeofday()?

From: Jelte Fennema-Nio <postgres(at)jeltef(dot)nl>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: Aleksander Alekseev <aleksander(at)timescale(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, "Andrey M(dot) Borodin" <x4mmm(at)yandex-team(dot)ru>
Subject: Re: What is a typical precision of gettimeofday()?
Date: 2024-03-20 18:35:20
Message-ID: CAGECzQT+62S7Uy0egu2fjWg3k7C-ZBX-3nwEpS8B3Woa9k8-bw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 20 Mar 2024 at 07:35, Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
> If we want to be robust without any guarantees from gettimeofday(), then
> arguably gettimeofday() is not the right underlying function to use for
> UUIDv7.

There's also clock_gettime which exposes its resolution using clock_getres

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Nathan Bossart 2024-03-20 18:35:27 Re: cleanup patches for incremental backup
Previous Message Robert Haas 2024-03-20 18:16:07 Re: documentation structure