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 1tGspl-001WCM-JR for pgsql-hackers@arkaria.postgresql.org; Fri, 29 Nov 2024 04:42:25 +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 1tGspi-003lRo-A3 for pgsql-hackers@arkaria.postgresql.org; Fri, 29 Nov 2024 04:42:23 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tGsph-003lRa-SJ for pgsql-hackers@lists.postgresql.org; Fri, 29 Nov 2024 04:42:23 +0000 Received: from fout-b3-smtp.messagingengine.com ([202.12.124.146]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tGspg-0006hp-1a for pgsql-hackers@lists.postgresql.org; Fri, 29 Nov 2024 04:42:21 +0000 Received: from phl-compute-11.internal (phl-compute-11.phl.internal [10.202.2.51]) by mailfout.stl.internal (Postfix) with ESMTP id DB72311400CC; Thu, 28 Nov 2024 23:42:18 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-11.internal (MEProxy); Thu, 28 Nov 2024 23:42:19 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1732855338; x=1732941738; bh=lPOzdzT2K7 x5iW3QYfC7wuqZXQNQKFvkDO/t1ayAh00=; b=BICAZQN8sbPtyy42ALIuFgl1j2 dmIDNgAmQrloOgtx4OIjgQ6EZkpBGvGrO6CNtXgBmpBo9ZjSxYzhE4C1ZSIR3Yra KROmsj5jbcR7g+Q3HzFsmZfqDLt+BvkZKsxzZmChd26DQ4t6t4t53RSNgkydG9ab Fgqo9JuOLS5IbTm+T/PAIgP53y1SbO5PRP/BVJshQLFB6/f3PO9+MClHxmwijCIu Jwrrjcr8sTVPgCGxHBN/zLYYnHrapacWylrLEXPrPbrtlMy496K65+rsoMBTvjmc jc3O69KKSPoIqmSodMJCNb+7yoDEt+hpoEIbeNhwxrEXh8thMPpTMVwOHIPQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1732855338; x=1732941738; bh=lPOzdzT2K7x5iW3QYfC7wuqZXQNQKFvkDO/ t1ayAh00=; b=Mfjke9UilrBvJO2tTB5o3N5KcIAzqgVZn8dbu5cx2ljelutFEmr ntFP/N6RPOPZPIEneNxA7i8bX1HlyDPJUfrr2jzyWS+h+K/RTSh+PxKmbFOAGuN3 /pSo9bZEQ1HTwsVhkLBkRqI/wJyauKVmnJ87OesFvwEEO8JLGCdwJyFWhIrDfCTn HXCjGsDGC7tCtVjjCqmU5wBbGlYHGHJ8fAsf37IBqr5VtzxGbwz/BRKZ/xNVqrT9 IBUp+b1OYqtlUQkdw9ji3jEWQASiUcGT1q/jovslDjNvm8hhBoMqaUVZ70fc4hML Y0+XnHvOGb56hU1xTTXfBjTXAkGx0Zxc1WQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrhedvgdejvdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth hsucdlqddutddtmdenfghrlhcuvffnffculdejtddmnecujfgurhepfffhvfevuffkfhgg tggujgesghdtreertddtvdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoe hmihgthhgrvghlsehprghquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpeetleei fedufffhhfdtteelgeeggeffhfekueevteeigfduudevudetgfegiedvjeenucevlhhush htvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehmihgthhgrvghlsehp rghquhhivghrrdighiiipdhnsggprhgtphhtthhopeegpdhmohguvgepshhmthhpohhuth dprhgtphhtthhopeiggehmmhhmseihrghnuggvgidqthgvrghmrdhruhdprhgtphhtthho pehmrghilhhinhhgshesohhophhsfigrrhgvrdguvgdprhgtphhtthhopehjihgrnhdruh hnihhvvghrshgrlhhithihsehgmhgrihhlrdgtohhmpdhrtghpthhtohepphhgshhqlhdq hhgrtghkvghrsheslhhishhtshdrphhoshhtghhrvghsqhhlrdhorhhg X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 28 Nov 2024 23:42:16 -0500 (EST) Date: Fri, 29 Nov 2024 13:42:03 +0900 From: Michael Paquier To: "Andrey M. Borodin" Cc: Bernd Helmle , jian he , PostgreSQL Hackers Subject: Re: [PATCH] Add sortsupport for range types and btree_gist Message-ID: References: <7C9400DF-66FE-4308-BAD8-92FE3D0E55C6@yandex-team.ru> <0d9fbd59de15e2fc987a850c3d1f8a79a6ede825.camel@oopsware.de> <19c62e62c79b727d2c9a82eaeecfea5017001099.camel@oopsware.de> <4BADF8DD-A4D3-43AA-AA08-037F6FFA40BC@yandex-team.ru> <61128550659807032dd29c8c8a71674c818cbbb6.camel@oopsware.de> <7095B5FA-FADB-4524-B858-ECD14998710B@yandex-team.ru> <0176b173adfcff250543fe0aee2ef6137bd71953.camel@oopsware.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ljOm7NlFYhHeD3nM" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --ljOm7NlFYhHeD3nM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Nov 28, 2024 at 11:32:59PM +0500, Andrey M. Borodin wrote: > Michael, we have 30 tests with checks that need injection > points. But these 30 tests also test functionality that needs to be > tested even in build without injection points.=20 > Do we have to extract checks with injection point into separate > regression test? So that we can exclude this test in builds without > injection points. I've looked at what the patch is doing with injection points, and that's incorrect. +CREATE EXTENSION injection_points; + +SELECT injection_points_attach('gist-sorted-build', 'notice'); This attaches points locally, meaning that this is going to create some noise for any tests running in parallel taking the same code path as where the point is created. To make tests able to run safely in a concurrent manner, please use injection_points_set_local(). As a bonus, your points would be automatically detached when the session turns off. Any module that requires the module injection_points to be installed can do a few things, none of them are done this way in this patch: - Add EXTRA_INSTALL=3Dsrc/test/modules/injection_points. - You could make a test able to run installcheck, but you should use an extra query that checks if the module is available for installation by querying pg_available_extensions and use two possible output files: one for the case where the module is *not* installed and one for the case where the module is installed. A simpler way would be to block installcheck, or add SQL tests in src/test/modules/injection_points. Both options don't seem adapted to me here as they impact the portability of existing tests. As a whole, I'm very dubious about the need for injection points at all here. The sortsupport property claimed for this patch tells that this results in smaller index sizes, but the tests don't really check that: they just make sure that sortsupport routine paths are taken. What this should test is not the path taken, but how the new code affects the index data generated. Perhaps pageinspect could be something to use to show the difference in contents, not sure though. The number of tests added to contrib/btree_gist/Makefile is not acceptable for a patch of this size, leading to a large bloat. And that's harder to maintain in the long-term. -- Michael --ljOm7NlFYhHeD3nM Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmdJRhsACgkQnvQgOdby QH1EaQ/+PIn7oCKYh63iYk4oPPobRoFXJgYfl+YqmwPQt9gTiZ4UgILpncHjaug2 eQgZHD3J38PhQBvVREFcjxrXBJ5LHinjg40BlPr1J9mhjsN5a+QDiruVdP4GTQKM fikA9ImLRGHkPQb1aosV/oGLrUMugjjTI41n6lkT+H2P07v2KOIO6yk1G7RQK4sl wg0mV9BZIwntLscn7K1UvB2eHkQdu83oQp5bRB++Ayqj96Bfc6yorGTcswSWsRVG lcf/Yd5i4a56rmEqA4gXeyf33zSUxyvvIGeQoZFfDsO/O6duRIHBBKgzWIAMaSCf Z+sJGAFERJG3Y9bJ+1R/X7ryyZwaiRoZygj+UCCwBZx6rHK/qDqCj9Yaf/lypYqT plxoJfAvv1cGe8ZWdgKrc3RobaSysmVDLNUiJUEBjF8PpDc2LpGHclKNSzZ/cFmb gxubEI04YR2ddku618x5d6AnBaZXqzwYy0BQQixmxRPW/DkhtCwj9TuvtdrXBF8v CCCUdlPTxFBzAEZY9WQ32XTuFNFOd4O48pKk0L14F2au72Pyvsz76PXbGFRbIpF9 iYCcw+582EEY3o5KWpiZi8/46ZrmQHxZ4QNUg4xcCkRYRiOxfbvzUQ1wPjeK6UGs NpGZqN+XYH2/6yn3bHBphawVkhTahl6byAJO0PzQuRiOKzV8vJI= =KXeh -----END PGP SIGNATURE----- --ljOm7NlFYhHeD3nM--