Re: Corrupted btree index on HEAD because of covering indexes - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: Corrupted btree index on HEAD because of covering indexes
Date
Msg-id CAH2-Wzk=QRA+vnL_sNxNVSYci8exQP-5gv4YOv-6xwTo480yKA@mail.gmail.com
Whole thread Raw
In response to Re: Corrupted btree index on HEAD because of covering indexes  (Teodor Sigaev <teodor@sigaev.ru>)
Responses Re: Corrupted btree index on HEAD because of covering indexes
Re: Corrupted btree index on HEAD because of covering indexes
List pgsql-hackers
On Tue, Apr 24, 2018 at 9:06 AM, Teodor Sigaev <teodor@sigaev.ru> wrote:
> Perfect!

Thanks!

> I would like to commit it but have some suggestions:

I attach a revised version, which has changes based on your feedback.

> to improve test stability it would be better to disable autovacuum:
> ALTER TABLE bttest_multi SET (autovacuum_enabled = false)

Done.

> 2) Pls, add to test DELETE as it done in
> 6db4b49986be3fe59a1f6ba6fabf9852864efc3e

Done. I will leave it to you to decide whether or not the original
create_index.sql test can now be removed.

> 3) It's not directly connected to this patch, but allocation of
> BtreeCheckState is not needed, it could be allocated on stack.
>
> 4) Nevertheless, I suggest to use palloc0 (or memset(0)) for
> BtreeCheckState. Now several fields of that structure could be not inited.

I like the idea of using palloc0(). Done that way.

-- 
Peter Geoghegan

Attachment

pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [HACKERS] Runtime Partition Pruning
Next
From: Andres Freund
Date:
Subject: Re: [HACKERS] Runtime Partition Pruning