Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tp2Pq-00HKVY-AM for pgsql-hackers@arkaria.postgresql.org; Mon, 03 Mar 2025 09:48:50 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tp2Pn-003FZz-TM for pgsql-hackers@arkaria.postgresql.org; Mon, 03 Mar 2025 09:48:47 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tp2Pn-003FZr-JG for pgsql-hackers@lists.postgresql.org; Mon, 03 Mar 2025 09:48:47 +0000 Received: from oss.nttdata.com ([49.212.34.109]) by magus.postgresql.org with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tp2Pk-000gKe-0I for pgsql-hackers@postgresql.org; Mon, 03 Mar 2025 09:48:47 +0000 Received: from [192.168.11.9] (p1695135-ipoe.ipoe.ocn.ne.jp [118.0.92.134]) by oss.nttdata.com (Postfix) with ESMTPSA id D89A461A53; Mon, 3 Mar 2025 18:48:41 +0900 (JST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at oss.nttdata.com Message-ID: Date: Mon, 3 Mar 2025 18:48:41 +0900 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: doc: Mention clock synchronization recommendation for hot_standby_feedback To: Jakub Wartak , Amit Kapila Cc: PostgreSQL Hackers References: Content-Language: en-US From: Fujii Masao In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2025/03/03 16:35, Jakub Wartak wrote: > Hi Amit, > > On Mon, Mar 3, 2025 at 6:26 AM Amit Kapila wrote: > [..] > > OK, sure. > >> How about something like: "Note that if the clock on standby is moved >> ahead or backward, the feedback message may not be sent at the >> required interval. This can lead to prolonged risk of not removing >> dead rows on primary for extended periods as the feedback mechanism is >> based on timestamp." > > Sure thing. I've just added '(..) In the extreme cases this can..' as > it is pretty rare to hit it. Patch attached. When the clock moves forward or backward, couldn't it affect not only the standby but also the primary? I’m wondering because TimestampDifferenceExceeds() seems to be used in several places in addition to hot standby feedback. Regards, -- Fujii Masao Advanced Computing Technology Center Research and Development Headquarters NTT DATA CORPORATION