Re: pg_basebackup may fail to send feedbacks. - Mailing list pgsql-hackers

From Kyotaro HORIGUCHI
Subject Re: pg_basebackup may fail to send feedbacks.
Date
Msg-id 20150210.213403.261969054.horiguchi.kyotaro@lab.ntt.co.jp
Whole thread Raw
In response to Re: pg_basebackup may fail to send feedbacks.  (Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>)
List pgsql-hackers
Hi,

15 19:48:23 +0900 (Tokyo Standard Time), Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp> wrote in
<20150210.194823.219136034.horiguchi.kyotaro@lab.ntt.co.jp>
> Considering pg_basebackup/receivexlog, the loop in receivelog.c
> does not maintain the time value within it, so I think we are
> forced to use feGetCurrentTimeStamp if not using SIGALRM. The wal
> reading function simply gets the data from the buffer in memory
> for most calls so the gettimeofday for each iteration could slow
> the process significantly. SIGALRM seems to be valuable for the
> case.

As a very fancy and ugly sample, the attached patch does this,
although, I'm a bit at a loss how to make this signal things to
be more sober..

-- 
Kyotaro Horiguchi
NTT Open Source Software Center

pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: What exactly is our CRC algorithm?
Next
From: Andres Freund
Date:
Subject: Re: Assertion failure when streaming logical changes