Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h8c5z-0003g5-6R for pgsql-bugs@arkaria.postgresql.org; Tue, 26 Mar 2019 02:45:47 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1h8c5x-0006Ek-Td for pgsql-bugs@arkaria.postgresql.org; Tue, 26 Mar 2019 02:45:45 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h8c5x-00067a-Ih for pgsql-bugs@lists.postgresql.org; Tue, 26 Mar 2019 02:45:45 +0000 Received: from wout1-smtp.messagingengine.com ([64.147.123.24]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h8c5v-0003Zg-7P for pgsql-bugs@lists.postgresql.org; Tue, 26 Mar 2019 02:45:44 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id E5C562D6F; Mon, 25 Mar 2019 22:45:41 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Mon, 25 Mar 2019 22:45:42 -0400 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=fm1; bh=uuRsPA26ieFoSUihQayl21Ttkt2 2FcoCNYM+pikw6NM=; b=b1D71Z5pWJIC3mwiPnNm6U1nAlmR7YEdEgXu3tit565 WOfhHSLQ7Uyx7NRaB5jcZ4Dk+ALys0CmTu6QRXozwkGA4PrYTln+jB60+d3amOi2 +eRe5T92OXA7iAMf0uU7uUcotUHEv/OGNpDe25m4Ex+MeBxxZVWWFrEChT9E/d7b DiI1pAX83L+decPgRTxuw6vJ9H+8ep7jPBepEz6d6VYAIQCdV+SvOoxj91XBu+Iv HbrFOUWpNTEIeJA76fITdIK1pGua5219VSWblpqrh2SRSCcjkasBz+6ekTlHhTGe XFMBNcSiggZu2C26EcGlAm3bsNmm84SJBPLT5NTg2Lw== 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=fm2; bh=uuRsPA 26ieFoSUihQayl21Ttkt22FcoCNYM+pikw6NM=; b=rQuJjWaDmIviR062dFCrIZ oiA3oKQ0cnChQOcIVWPh47nqobRP9vHLAqMtBURH2D9INEtiGm0G5qEQ1fV9Fz/8 PMN3649CGdKOyqnxG5iKDDWDDO2ZHqoB+aWyD1NSvXMgwJQO01AxhbKWo/sI6f2F 7jsx8DUlTfWDwYSHvNWdF/KWnWbeTahf0jQ7qv4gidX36CYqKK+W3quLZo37JgFU MkkuHkKwRnDZ8mLrEqewkvjAle/Z327kBpoe7dPzHoswuO1sJY3ev0qUZRKSQExQ mu3aQCRNQ0LnnW8SvinL8OVQ06XEnwpL07l8imTbH+7LCT1hrt+ZQuV50H7yYqCQ == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedutddrjeelgdehtdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenfg hrlhcuvffnffculdejtddmnecujfgurhepfffhvffukfhfgggtuggjsehgtderredttddv necuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesphgrqh huihgvrhdrgiihiieqnecukfhppeduudekrddvgedurddvhedtrdekleenucfrrghrrghm pehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqhhuihgvrhdrgiihiienucevlhhush htvghrufhiiigvpedt X-ME-Proxy: Received: from paquier.xyz (mp76f1fa59.ap.nuro.jp [118.241.250.89]) by mail.messagingengine.com (Postfix) with ESMTPA id 6B95510390; Mon, 25 Mar 2019 22:45:39 -0400 (EDT) Date: Tue, 26 Mar 2019 11:45:27 +0900 From: Michael Paquier To: Peter Eisentraut Cc: Tom Lane , dnsl48@gmail.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #15631: Generated as identity field in a temporary table with on commit drop corrupts system catalogs Message-ID: <20190326024527.GS2558@paquier.xyz> References: <24188.1549917188@sss.pgh.pa.us> <043b0c10-5a27-b9ff-7451-b8a2ca9327b1@2ndquadrant.com> <31358.1549981670@sss.pgh.pa.us> <20190213023817.GD5746@paquier.xyz> <20190213044104.GE5746@paquier.xyz> <12a993ea-1ba5-96d7-a0b5-362579fdadc1@2ndquadrant.com> <20190309013557.GF9266@paquier.xyz> <20190312034630.GH13812@paquier.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="lzfPtAjrR1KYNfg0" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --lzfPtAjrR1KYNfg0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Mar 13, 2019 at 10:28:11AM +0100, Peter Eisentraut wrote: > /* Need CCI between commands */ > - if (lnext(l) != NULL) > CommandCounterIncrement(); Hmm. We could actually live with this suggestion, and this impacts only CREATE TABLE and ALTER TABLE statements. I would still add a CCI after the internal dependency between the identity sequence and its root table is recorded though as there could be other callers of the internal sequence API, so a CCI only in utility.c may not be enough. > I think we should also make the implicitly created sequence temporary. > Even though the permanent sequence is cleaned up properly, we should > avoid having those sequences write to the WAL. Indeed, sounds good to me. -- Michael --lzfPtAjrR1KYNfg0 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAlyZkkcACgkQnvQgOdby QH00iQ//SpRmlcPn6k+gnwgZILBWX+wc+LiCOHkaOBX5J7sTEt3TH2WnS6aqZEqx +JPYOrQlajhzzzO15lgqB2MjWmBQ4tM7pKIsVNDmrKSbDGmov3qQzJroE57SZYle +YW5xdteCa3pXNyZ/huOLwzNdNLGqrPuMrkeko03Ya8c9vFyGFb1DOtqsiJcaF3X eN0My3XXLsm3GyjolEj8aGvPvlY1TbUWuFDptI6GgBvEAhR3Yg88wAABZBsHvoGK s4T6PkgYM7LnSJcTvgZGj80qNhgamuXn5PFoFxYAKV0ASfH5cdf9/qolNRLCgxUU Wxe1uPL6qevttXamXGhiIb+063DTj43INEBujWfriNGZh0MfufgZLag6xLBOv8+k BuUCNd4Bi5AurCnN19dXPzbiDnedIjDzO8wVJsudJXfZkRO+16ZcRpN0+bky9Edk OZ3COws4KAt4mLdGfpMW93/mHKR0wDpJnFJoHaL3faSfullVkOJlgvPK1X468uoQ Qk/4wxjLJZTcbLl/2cQScBkpYDw73DtS8XG+vdww4z491bWqnvVi6aWGDgo8a7V6 SD5GZXHHfEGxfSmbFJn8Owre6DM9mKwczTm46bii5eg0D75pWMWoSiVPh+wKVBpF yQdRU0Msld7DjZZI6Ghx50xhYxXjwkxb6j+j9jyKK7sP30p4BsM= =k8r/ -----END PGP SIGNATURE----- --lzfPtAjrR1KYNfg0--