From: | Noah Misch <noah(at)leadboat(dot)com> |
---|---|
To: | Nazir Bilal Yavuz <byavuz81(at)gmail(dot)com> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Use read streams in CREATE DATABASE command when the strategy is wal_log |
Date: | 2024-07-23 12:34:00 |
Message-ID: | 20240723123400.64@rfd.leadboat.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Jul 22, 2024 at 12:00:45PM +0300, Nazir Bilal Yavuz wrote:
> On Sat, 20 Jul 2024 at 21:14, Noah Misch <noah(at)leadboat(dot)com> wrote:
> > On a different naming topic, my review missed that field name
> > copy_storage_using_buffer_read_stream_private.last_block doesn't fit how the
> > field is used. Code uses it like an nblocks. So let's either rename the
> > field or change the code to use it as a last_block (e.g. initialize it to
> > nblocks-1, not nblocks).
>
> I prefered renaming it as nblocks, since that is how it was used in
> RelationCopyStorageUsingBuffer() before. Also, I realized that instead
> of setting p.blocknum = 0; initializing blkno as 0 and using
> p.blocknum = blkno makes sense. Because, p.blocknum and blkno should
> always start with the same block number. The relevant patch is
> attached.
I felt the local variable change was not a clear improvement. It would have
been fine for the original patch to do it in that style, but the style of the
original patch was also fine. So I've pushed just the struct field rename.
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2024-07-23 12:38:47 | Re: replace strtok() |
Previous Message | Jeremy Schneider | 2024-07-23 12:31:56 | Re: [18] Policy on IMMUTABLE functions and Unicode updates |