Re: tracking commit timestamps - Mailing list pgsql-hackers

From Anssi Kääriäinen
Subject Re: tracking commit timestamps
Date
Msg-id 1415602866.8931.127.camel@TTY32
Whole thread Raw
In response to Re: tracking commit timestamps  (Steve Singer <steve@ssinger.info>)
Responses Re: tracking commit timestamps  (Petr Jelinek <petr@2ndquadrant.com>)
Re: tracking commit timestamps  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On Sun, 2014-11-09 at 11:57 -0500, Steve Singer wrote:

> The reason why Jim and myself are asking for the LSN and not just the 
> timestamp is that I want to be able to order the transactions. Jim 
> pointed out earlier in the thread that just ordering on timestamp allows 
> for multiple transactions with the same timestamp.
> 
> Maybe we don't need the entire LSN to solve that.  If you already have 
> the commit timestamp maybe you only need another byte or two of 
> granularity to order transactions that are within the same microsecond.

There is no guarantee that a commit with later LSN has a later
timestamp. There are cases where the clock could move significantly
backwards.

A robust solution to storing transaction commit information (including
commit order) in a way that can be referenced from other tables, can be
loaded to another cluster, and survives crashes would be a great
feature. But this feature doesn't have those properties.
- Anssi





pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: pg_multixact not getting truncated
Next
From: Etsuro Fujita
Date:
Subject: Re: PENDING_LIST_CLEANUP_SIZE - maximum size of GIN pending list Re: HEAD seems to generate larger WAL regarding GIN index