From: Bossart, Nathan <bossartn@amazon.com>
To: Dipesh Pandit <dipesh.pandit@gmail.com>
To: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Jeevan Ladhe <jeevan.ladhe@enterprisedb.com>
Cc: Stephen Frost <sfrost@snowman.net>
Cc: Andres Freund <andres@anarazel.de>
Cc: Hannu Krosing <hannuk@google.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: .ready and .done files considered harmful
Date: Thu, 9 Sep 2021 22:24:30 +0000
Message-ID: <81436B91-9A78-4CE1-BCDF-142F32FDF1DE@amazon.com> (raw)
In-Reply-To: <CAN1g5_Fv8Dk5fUYT9JNLZVi7_ObKEUugGS8SUEu3Bs+BJHWQyQ@mail.gmail.com>
References: <B77F8791-947C-4FF5-8D82-BA251E1B9F9D@amazon.com>
<CA+TgmoYupCw+cORkcM0Ut2fsGLd5srnRYmebjr2N+jYzbUX1-w@mail.gmail.com>
<6FEECA73-709B-4896-836D-B481AA4678EB@amazon.com>
<20210908.151632.636932907306042031.horikyota.ntt@gmail.com>
<CAN1g5_Fv8Dk5fUYT9JNLZVi7_ObKEUugGS8SUEu3Bs+BJHWQyQ@mail.gmail.com>
On 9/8/21, 10:49 AM, "Dipesh Pandit" <dipesh.pandit@gmail.com> wrote:
> Updated log level to DEBUG3 and rebased the patch. PFA patch.
Thanks for the new patch.
+ * by checking the availability of next WAL file. "xlogState" specifies the
+ * segment number and timeline ID corresponding to the next WAL file.
"xlogState" probably needs to be updated here.
As noted before [0], I think we need to force a directory scan at the
beginning of pgarch_MainLoop() and when pgarch_ArchiverCopyLoop()
returns before we exit the "while" loop. Else, there's probably a
risk that we skip archiving a file until the next directory scan. IMO
forcing a directory scan at the beginning of pgarch_ArchiverCopyLoop()
is a simpler way to do roughly the same thing. I'm skeptical that
persisting the next-anticipated state between calls to
pgarch_ArchiverCopyLoop() is worth the complexity.
Nathan
[0] https://www.postgresql.org/message-id/AC78607B-9DA6-41F4-B253-840D3DD964BF%40amazon.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: bossartn@amazon.com, dipesh.pandit@gmail.com, horikyota.ntt@gmail.com, robertmhaas@gmail.com, jeevan.ladhe@enterprisedb.com, sfrost@snowman.net, andres@anarazel.de, hannuk@google.com
Subject: Re: .ready and .done files considered harmful
In-Reply-To: <81436B91-9A78-4CE1-BCDF-142F32FDF1DE@amazon.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox