On Thu, Oct 5, 2017 at 10:59 PM, Robert Haas <robertmh...@gmail.com> wrote:
> This patch wasn't formatted very nicely; attached is a version that
> pgindent likes better and doesn't bust past 80 columns.
>
> I think this patch needs significantly better comments.  There's no
> explanation of the rather complex formula the patch proposed to use.
> Maybe it's just copied from someplace else that does have a comment,
> but in that case, the comments here should mention that.  And the
> comment in the other place should probably be updated too, like:
>
> /* Make sure to keep this in sync with the similar logic in
> XLogDoAwesomeStuff() */

I have just gone through this thread, and reducing the amount of times
the WAL writer is woken up is something worth doing. The last version
if v3 that Robert has sent in
https://www.postgresql.org/message-id/CA+TgmoZhw_nyrxYUqSuDh-XEJya-YzfwShki5NuDS=ufgvo...@mail.gmail.com.
As far as I can see, the smarter formula presented here comes from
XLogBackgroundFlush(). Jeff, could you update the patch to reflect
that the new condition you are adding comes from there? I am switching
the patch as "waiting on author" for now.
--
Michael

Reply via email to