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 1oYZIU-0007FX-T7 for pgsql-hackers@arkaria.postgresql.org; Wed, 14 Sep 2022 20:47: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 1oYZIT-0006T9-OP for pgsql-hackers@arkaria.postgresql.org; Wed, 14 Sep 2022 20:47:49 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oYZIT-0006QA-Ex for pgsql-hackers@lists.postgresql.org; Wed, 14 Sep 2022 20:47:49 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oYZIO-00028y-Ft for pgsql-hackers@postgresql.org; Wed, 14 Sep 2022 20:47:45 +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 28EKlNAL2884266; Wed, 14 Sep 2022 16:47:23 -0400 From: Tom Lane To: Peter Eisentraut cc: Nathan Bossart , =?UTF-8?Q?Benoit_Lobr=c3=a9au?= , Alvaro Herrera , Robert Haas , "Bossart, Nathan" , David Steele , Fujii Masao , "pgsql-hackers@postgresql.org" , Michael Paquier , Magnus Hagander , Stephen Frost Subject: Re: archive modules In-reply-to: <37857474-5caa-ccb3-92a3-150ddfe851ab@enterprisedb.com> References: <20220824221723.GA1347845@nathanxps13> <20220825200600.GA1465148@nathanxps13> <20220829224621.GB541895@nathanxps13> <20220830163048.GA544233@nathanxps13> <613541.1662842656@sss.pgh.pa.us> <20220910211046.GA2651323@nathanxps13> <9ee5d180-2c32-a1ca-d3d7-63a723f68d9a@enterprisedb.com> <20220914200305.GA2984249@nathanxps13> <37857474-5caa-ccb3-92a3-150ddfe851ab@enterprisedb.com> Comments: In-reply-to Peter Eisentraut message dated "Wed, 14 Sep 2022 22:07:11 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2884264.1663188443.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Wed, 14 Sep 2022 16:47:23 -0400 Message-ID: <2884265.1663188443@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Peter Eisentraut writes: > On 14.09.22 22:03, Nathan Bossart wrote: >> I originally did it this way, but changed it based on this feedback [0]= . I >> have no problem with the general idea, but the recovery_target_* logic = does >> have the following note: >> = >> * XXX this code is broken by design. Throwing an error from a GUC assi= gn >> * hook breaks fundamental assumptions of guc.c. So long as all the var= iables >> * for which this can happen are PGC_POSTMASTER, the consequences are li= mited, >> * since we'd just abort postmaster startup anyway. Nonetheless it's li= kely >> * that we have odd behaviors such as unexpected GUC ordering dependenci= es. > Ah yes, that won't work. But maybe we can just check it at run time, = > like in LoadArchiveLibrary(). Yeah, the objection there is only to trying to enforce such interrelationships in GUC hooks. In this case it seems to me that we could easily check and complain at the point where we're about to use the GUC values. regards, tom lane