From: | Teodor Sigaev <teodor(at)sigaev(dot)ru> |
---|---|
To: | Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru>, Peter Geoghegan <pg(at)bowt(dot)ie> |
Cc: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, pgsql-committers <pgsql-committers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi |
Date: | 2018-04-19 08:29:38 |
Message-ID: | 7152e7dd-4448-8e9b-1e28-8139035a1fd4@sigaev.ru |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Thank you, both patches are pushed.
Alexander Korotkov wrote:
> On Wed, Apr 18, 2018 at 9:21 PM, Peter Geoghegan <pg(at)bowt(dot)ie
> <mailto:pg(at)bowt(dot)ie>> wrote:
>
> On Wed, Apr 18, 2018 at 11:12 AM, Fujii Masao <masao(dot)fujii(at)gmail(dot)com
> <mailto:masao(dot)fujii(at)gmail(dot)com>> wrote:
> > On Thu, Apr 5, 2018 at 1:29 AM, Teodor Sigaev <teodor(at)sigaev(dot)ru <mailto:teodor(at)sigaev(dot)ru>> wrote:
> >> Skip full index scan during cleanup of B-tree indexes when possible
> >
> > This commit added XLOG_BTREE_META_CLEANUP, so btree_desc() and
> > btree_identify() should be updated so that they handle XLOG_BTREE_META_CLEANUP.
> > But ISTM that you forgot doing that.
>
> Thank you for notice. See attached
> bt-vacuum-cleanup-wal-record-desc-identify.patch fixing that.
>
> Another thing that I noticed is that the metapage stores
> btm_last_cleanup_num_heap_tuples as a float4, even though
> xl_btree_metadata stores it as a double. I suggest that both places
> store it as float8, to be consistent. (It should not be double because
> we always avoid using anything other types with explicit typedef'd
> widths in WAL records.)
>
>
> Good catch, thank you! I also agree that both these fields should be of float8
> type.
> Please, find attached bt-vacuum-cleanup-float8-num-heap-tuples.patch fixing that.
>
> ------
> Alexander Korotkov
> Postgres Professional:http://www.postgrespro.com <http://www.postgrespro.com/>
> The Russian Postgres Company
>
--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2018-04-19 13:58:02 | pgsql: Enlarge find_other_exec's meager fgets buffer |
Previous Message | Teodor Sigaev | 2018-04-19 08:29:03 | pgsql: Fix datatype for number of heap tuples during last cleanup |