Re: Multiple FPI_FOR_HINT for the same block during killing btree index items

From: James Coleman <jtc331(at)gmail(dot)com>
To: Peter Geoghegan <pg(at)bowt(dot)ie>
Cc: Masahiko Sawada <masahiko(dot)sawada(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Álvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Subject: Re: Multiple FPI_FOR_HINT for the same block during killing btree index items
Date: 2020-04-10 01:47:27
Message-ID: CAAaqYe8Lt+udOASNpyuQoXMKo8Prg7Rcyc2mCK5NYteLF4CHBw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Apr 9, 2020 at 8:32 PM Peter Geoghegan <pg(at)bowt(dot)ie> wrote:
>
> On Thu, Apr 9, 2020 at 5:25 PM Peter Geoghegan <pg(at)bowt(dot)ie> wrote:
> > Was this a low cardinality index in the way I describe? If it was,
> > then we can hope (and maybe even verify) that the Postgres 12 work
> > noticeably ameliorates the problem.
>
> What I really meant was an index where hundreds or even thousands of
> rows for each distinct timestamp value are expected. Not an index
> where almost every row has a distinct timestamp value. Both timestamp
> index patterns are common, obviously.

I'll try to run some numbers tomorrow to confirm, but I believe that
the created_at value is almost (if not completely) unique. So, no,
it's not a low cardinality case like that.

I believe the write pattern to this table likely looks like:
- INSERT
- UPDATE
- DELETE
for every row. But tomorrow I can do some more digging if needed.

James

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro Horiguchi 2020-04-10 02:00:31 Re: [BUG] non archived WAL removed during production crash recovery
Previous Message Andres Freund 2020-04-10 01:20:10 Re: Catalog invalidations vs catalog scans vs ScanPgRelation()