Re: Add 64-bit XIDs into PostgreSQL 15

From: Maxim Orlov <orlovmg(at)gmail(dot)com>
To: Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Add 64-bit XIDs into PostgreSQL 15
Date: 2022-01-08 08:48:41
Message-ID: CACG=ezY7WZToLsY5kuFjkUSYrr8w2cv3X+_TZT5+P8=FPtnZ=A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> Is there any documentation or README explaining this whole 64-bit XID
> mechanism?
>
There is none, unfortunately. I would come back to this later.

> Could you tell me what happens if new tuple with XID larger than xid_base
> + 0xFFFFFFFF is inserted into the page? Such new tuple is not allowed to be
> inserted into that page? Or xid_base and xids of all existing tuples in the
> page are increased? Also what happens if one of those xids (of existing
> tuples) cannot be changed because the tuple still can be seen by
> very-long-running transaction?
>
All this mechanism is around heap_insert/heap_update by
calling heap_page_prepare_for_xid() and if it fails (due to tuple still
visible) error is raised. Also If xid_base shift is not viable, it will try
to remove old tuples.

--
Best regards,
Maxim Orlov.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2022-01-08 10:05:08 Re: Non-superuser subscription owners
Previous Message Maxim Orlov 2022-01-08 08:21:20 Re: Add 64-bit XIDs into PostgreSQL 15