Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oddhi-00056o-8e for pgsql-hackers@arkaria.postgresql.org; Wed, 28 Sep 2022 20:30:50 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oddhh-0003Cz-71 for pgsql-hackers@arkaria.postgresql.org; Wed, 28 Sep 2022 20:30:49 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oddhg-0003CX-Tr for pgsql-hackers@lists.postgresql.org; Wed, 28 Sep 2022 20:30:48 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oddha-0002tb-5q for pgsql-hackers@postgresql.org; Wed, 28 Sep 2022 20:30:48 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 28SKUbZ74035600; Wed, 28 Sep 2022 16:30:37 -0400 From: Tom Lane To: Kyotaro Horiguchi cc: bdrouvot@amazon.com, sawada.mshk@gmail.com, ashutosh.bapat.oss@gmail.com, pgsql-hackers@postgresql.org Subject: Re: more descriptive message for process termination due to max_slot_wal_keep_size In-reply-to: <20220908.134020.228552226800754222.horikyota.ntt@gmail.com> References: <03ee95c3-6496-90b7-5c8b-13fe69ee73dd@amazon.com> <20220907.112019.758274712731312487.horikyota.ntt@gmail.com> <95534909-b8a0-d447-b940-b91006397962@amazon.com> <20220908.134020.228552226800754222.horikyota.ntt@gmail.com> Comments: In-reply-to Kyotaro Horiguchi message dated "Thu, 08 Sep 2022 13:40:20 +0900" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <4035598.1664397037.1@sss.pgh.pa.us> Content-Transfer-Encoding: 8bit Date: Wed, 28 Sep 2022 16:30:37 -0400 Message-ID: <4035599.1664397037@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Kyotaro Horiguchi writes: > Okay. the points you brought up above are sufficient grounds for not > doing so. Now they are in the following format. > LOG: terminating process 16034 to release replication slot "rep1" > because its restart_lsn 0/3158000 exceeds the limit by 15368192 bytes This seems to me to be a pretty blatant violation of our first message style guideline [1]: The primary message should be short, factual, and avoid reference to implementation details such as specific function names. “Short” means “should fit on one line under normal conditions”. Use a detail message if needed to keep the primary message short ... I think you should leave the primary message alone and add a DETAIL, as the first version of the patch did. The existing "invalidating slot" message is already in violation of this guideline, so splitting off a DETAIL from that seems indicated as well. regards, tom lane [1] https://www.postgresql.org/docs/devel/error-style-guide.html