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 1my0b7-00044m-5E for pgsql-hackers@arkaria.postgresql.org; Thu, 16 Dec 2021 23:55:41 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1my0b5-000092-CQ for pgsql-hackers@arkaria.postgresql.org; Thu, 16 Dec 2021 23:55:39 +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 1my0b3-00008t-Gr for pgsql-hackers@lists.postgresql.org; Thu, 16 Dec 2021 23:55:39 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1my0az-00088c-Mr for pgsql-hackers@lists.postgresql.org; Thu, 16 Dec 2021 23:55:37 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id C648E5C019E; Thu, 16 Dec 2021 18:55:29 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Thu, 16 Dec 2021 18:55:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm3; bh=wYansOEPhg87l+1i5seOAcTEP5J AhGOwCUuVbEcrFdk=; b=lu9TMADTZ6CVo6YisSMg4zWpUyDLIQodSY/KFTUWU1T shUnc0bVAUn5/E4zfQrHtTpfPcG6DxZr6JVOl4wmGgT3IkkA1acyRmYQq6bhMhn1 j5PvW+lK3QWfCs8xE4+UT/3NLpzvi5fulQKAmgq63d2Bc8QGgsgccxS7JbpX3aEG ON65Y+jgsGpsRNFDJ5hrD8IplDq9TQSkS3PxJ+nzwwYV7SDWxvrv8KWqD2ffK+QJ TV/sI1zxv4nP9OTSVweJLdRnoqSkugad1kUyVGXGUeP7fcmwhvOskxZMQ7Ba4g69 q8xYB1Gsxhe46efW3U3+GXODdQWQGUGv5YjUAm+gG+Q== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=wYansO EPhg87l+1i5seOAcTEP5JAhGOwCUuVbEcrFdk=; b=Pt8hzbtcI6oq2Xh3lF95MP JxA7w2aR4xXphyzPfBe54xHT2hO5Q9XuH7jbLWAuMG/rfrrK7ve+JbHWZ1JpAfAD QFT6V3sX01ldLqS1gk6t3WgZQwTeOUptQ3D9RBkel5M4iCXzIa6JOQCjt0EtX0hd prbjkVI3Rtkf0O0SFCbjhO3UCiGpq4+4xJAxfmPuy/B3G0QK9B2Wv+LNeccoivAd HmoAy3V/1ld8XMkqpJRzu7UEieDJUYLy44woQ1NWyVP8Fx0psyrAaJ3/3Yx3sCAt C/L7npTXZ5VcdhuZiPwgvVWxFLjT8/VTC+2h+10e9Jym1jkxmZGt2i6Z+NhZ7pVg == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvuddrleehgddufecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenfg hrlhcuvffnffculdejtddmnecujfgurhepfffhvffukfhfgggtuggjsehgtderredttddv necuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesphgrqh huihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepvdegudeuhfdtueeltedtveejheeh ieevueeigeelteegleejleeiueeiheegvefhnecuvehluhhsthgvrhfuihiivgeptdenuc frrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqhhuihgvrhdrgiihii X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 16 Dec 2021 18:55:27 -0500 (EST) Date: Fri, 17 Dec 2021 08:55:23 +0900 From: Michael Paquier To: Alvaro Herrera Cc: Ashutosh Bapat , "wangw.fnst@fujitsu.com" , "pgsql-hackers@lists.postgresql.org" , Andres Freund Subject: Re: Confused comment about drop replica identity index Message-ID: References: <202112161808.lxanl3r7skol@alvherre.pgsql> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="9WY6T/U+Y+XOxxlk" Content-Disposition: inline In-Reply-To: <202112161808.lxanl3r7skol@alvherre.pgsql> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --9WY6T/U+Y+XOxxlk Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Dec 16, 2021 at 03:08:46PM -0300, Alvaro Herrera wrote: > Hmm, so if a table has REPLICA IDENTITY INDEX and there is a publication > with an explicit column list, then we need to forbid the DROP INDEX for > that index. Hmm. I have not followed this thread very closely. > I wonder why don't we just forbid DROP INDEX of an index that's been > defined as replica identity. It seems quite silly an operation to > allow. The commit logs talk about b23b0f55 here for this code, to ease the handling of relcache entries for rd_replidindex. 07cacba is the origin of the logic (see RelationGetIndexList). Andres? I don't think that this is really an argument against putting more restrictions as anything that deals with an index drop, including the internal ones related to constraints, would need to go through index_drop(), and new features may want more restrictions in place as you say. Now, I don't see a strong argument in changing this behavior either (aka I have not looked at what this implies for the new publication types), and we still need to do something for the comment/docs in existing branches, anyway. So I would still fix this gap as a first step, then deal with the rest on HEAD as necessary. -- Michael --9WY6T/U+Y+XOxxlk Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmG70esACgkQnvQgOdby QH3mqA/+LhC7UX1KYMfdnoiwRUtSjJ9/NbY89E3Ws3QR8qzWxBrLFdhBAlXMm/cK 5g6m0L7VYs//WGQ97n6VJGKUwU5zHDusWK4JSx4+iMG+HfNNJWDpN449d1ux12cj ouAjsDYpats8rHz2kD18gRPXdqlm5pa2pFz0x+rRlR7YDi4ZK/FsYwlUJX7J2rdK csxf2cuJF2baz5d6kCpHs6/dEEVNk3UV0xsSwWHdDM5gWG/oHFMo8bm1TW/a/6V2 v/EkYPV8SkEUnbLnT7dys2Nj/ZBqaFo+6vEQnlgfjNeD7t80Qy3TuO7K6pv1s9g5 cjY39dp8MUx8Pn7YYfYU7/JS/g5yjHdfZPjrRlFWNzH8QojrMyB1u5k2lsPiWjvf 9y5FES05UcuTgZepE++w0eQcD2fmJgSxojDTtjumKpsxPnVUBrnp+YEgm3q2jhXC hgbA0UbfwRCJhjJXncSUyix2lWuoaZtxRLvdFhn7iFybK8a3aFlay3CjK+ITXAoY 0j8hrMySdTznVoyu58OQ4Kc0YxSQS+zOY+i0Tnu2TXVfDPDA1B93Tim6FFB2uA7+ xnlJoq1pgpjOQBXTmZUJrRApK+Yw1nk3RA6k09BtRsMhVXsEvLWZlpzwHS9NOzGN HGQNp2nXMh0NdOCCbwEYQT0JXoVXKQHjo3TAtEJ79tGmNX4x61U= =yOLp -----END PGP SIGNATURE----- --9WY6T/U+Y+XOxxlk--