Re: Removal of currtid()/currtid2() and some table AM cleanup

From: "Inoue, Hiroshi" <h-inoue(at)dream(dot)email(dot)ne(dot)jp>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Hiroshi Saito <hiroshi(at)winpg(dot)jp>, "Tsunakawa, Takayuki" <tsunakawa(dot)takay(at)jp(dot)fujitsu(dot)com>
Subject: Re: Removal of currtid()/currtid2() and some table AM cleanup
Date: 2020-06-24 08:20:42
Message-ID: af762e97-9efc-7f8b-2d48-1c487ed42b3d@dream.email.ne.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Michael,

Where do you test, on Windows or on *nix?
How do you test there?

regards,
Hiroshi Inoue

On 2020/06/24 11:11, Michael Paquier wrote:
> On Tue, Jun 23, 2020 at 02:02:33PM +0900, Michael Paquier wrote:
>> Actually, while reviewing the code, the only code path where we use
>> currtid2() involves positioned_load() and LATEST_TUPLE_LOAD. And the
>> only location where this happens is in SC_pos_reload_with_key(), where
>> I don't actually see how it would be possible to not have a keyset and
>> still use a CTID, which would led to LATEST_TUPLE_LOAD being used. So
>> could it be possible that the code paths of currtid2() are actually
>> just dead code?
> I have dug more into this one, and we actually stressed this code path
> quite a lot up to commit d9cb23f in the ODBC driver, with tests
> cursor-block-delete, positioned-update and bulkoperations particularly
> when calling SQLSetPos(). However, 86e2e7a has reworked the code in
> such a way that we visibly don't use anymore CTIDs if we don't have a
> keyset, and that combinations of various options like UseDeclareFetch
> or UpdatableCursors don't trigger this code path anymore. In short,
> currtid2() does not get used. Inoue-san, Saito-san, what do you
> think? I am adding also Tsunakawa-san in CC who has some experience
> in this area.
> --
> Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message tushar 2020-06-24 08:24:29 Re: [Patch] ALTER SYSTEM READ ONLY
Previous Message Vik Fearing 2020-06-24 08:12:38 Re: Allow CURRENT_ROLE in GRANTED BY