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 1oyt9l-0001Bm-NQ for pgsql-committers@arkaria.postgresql.org; Sat, 26 Nov 2022 11:15:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oyt9k-0003VY-BA for pgsql-committers@arkaria.postgresql.org; Sat, 26 Nov 2022 11:15:36 +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 1oyt9i-0003VO-MC for pgsql-committers@lists.postgresql.org; Sat, 26 Nov 2022 11:15:36 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oyt9d-0007L1-BK for pgsql-committers@lists.postgresql.org; Sat, 26 Nov 2022 11:15:33 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 5EC7D5C006D; Sat, 26 Nov 2022 06:15:26 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Sat, 26 Nov 2022 06:15:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to; s=fm1; t=1669461326; x=1669547726; bh=KSIzYhu9Y1 nIE9Jbi3KYy0+nZB3vq+oCOJ7jiQbHMQI=; b=u7mzLzen+mBgYh1TokARM01srI 4KpDlNzNXCTH1MsbIQSWR70Vqq4mKWOkY7syKlTEvqS+k/bAmk7IlvdTDIB7Cj5U K1NkacP1kS3ME88UR+3kHQ1SmnGZWBA4tzi/R79v4rAkBV98pBMKugeypuJS0NrU su5ug5k8mVeWr7kyRG/UZMBHcbiKorgwhAkH/qInj2Yguxr5kaiSp69lubetZCFE pIMahiASxIk7akT2EQ3Ztn+yDzFZg1fi0N/3vsRiBdvjvaXKy9v9KKSpNa7vYDaN 8PadxGdNVJMrL1xbIyIyZAJ6tdQlv6eLvjydYfVRFzvPv1Ox0PjY9//cYoCQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:feedback-id :feedback-id:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1669461326; x=1669547726; bh=KSIzYhu9Y1nIE9Jbi3KYy0+nZB3v q+oCOJ7jiQbHMQI=; b=MgNz44NnEtYcsXsvWaFvKugya6qa+xN9QubkRTrh10BP ACODKuutgLAcJwAsozotyx2xh9nsLiB876sml02NADmPxd5fRS/3E1w7Bamt1ayB JQvyoETuKzyfBJ+c+l3LQnevhRvsqZ6qeSAD1Jrlj14RcGt9rf5omBFAqbmM+l8z 93ycCuNcP74t3qBluPThZYDQM32QuRjbPZxKv6qBms/gmuI2Ss+48GLATDt/dOM2 9NVJ7QWicLDyHmjCZw1+jvRbXP7PVuvENtdyYMzZniHERCQ+Ib4hAPk0uVhuR94Z TQUq7SgKMXR3kJ9JSThVISU3HYc369M5elZRjQFfIA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvgedrieejgddvjecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenfg hrlhcuvffnffculdejtddmnecujfgurhepfffhvfevuffkfhggtggujgesghdtreertddt vdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoehmihgthhgrvghlsehprg hquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpeetleeifedufffhhfdtteelgeeg geffhfekueevteeigfduudevudetgfegiedvjeenucevlhhushhtvghrufhiiigvpedtne curfgrrhgrmhepmhgrihhlfhhrohhmpehmihgthhgrvghlsehprghquhhivghrrdighiii X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sat, 26 Nov 2022 06:15:24 -0500 (EST) Date: Sat, 26 Nov 2022 20:15:19 +0900 From: Michael Paquier To: Andrew Dunstan Cc: pgsql-committers@lists.postgresql.org Subject: Re: pgsql: Prevent port collisions between concurrent TAP tests Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="U1N8xVn0y2CA9aW1" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --U1N8xVn0y2CA9aW1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Andrew, On Tue, Nov 22, 2022 at 03:56:43PM +0000, Andrew Dunstan wrote: > Prevent port collisions between concurrent TAP tests >=20 > Currently there is a race condition where if concurrent TAP tests both > test that they can open a port they will assume that it is free and use > it, causing one of them to fail. To prevent this we record a reservation > using an exclusive lock, and any TAP test that discovers a reservation > checks to see if the reserving process is still alive, and looks for > another free port if it is. >=20 > Ports are reserved in a directory set by the environment setting > PG_TEST_PORT_DIR, or if that doesn't exist a subdirectory of the top > build directory as set by Makefile.global, or its own > tmp_check directory. Wouldn't it be better to update .gitgnore at the root of the source folder to discard portlock/ so as we will never include by accident in a commit? Thanks, -- Michael --U1N8xVn0y2CA9aW1 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmOB9UcACgkQnvQgOdby QH18lQ//Yk8XrLyUe0ozDN2yBxAJB6XGIRXsgxYLVcawgJcN/Ki4+1htjw1BECSX 88iOV1RATpI23vll2e5DEYG9Ok4vblax4WIStiqLrntxLLg3yFH9gg8x78KqCFIn DAuGdAnjyn8Pr4aHKOvm53tU33idsqVlDw24So1LtfE+xnHGgdyqibvaSpE26KbZ rYfi9wEOUiy9deoRdLm70hH08x4HW9RGFhQ0Ae9uxT2GKdIQboxqROg9llDo9n7+ uGeWVBTcJBtlaTtuxUEWZ0b0x8vSnItLnI2u9iyrD+nnqKUWSwAivxirbbE66KYZ 1cYnNPSc+8t1vdq/g0L4xoea7HhAPT5A1thm1N7gCcFeYNLoPfHONbhkm0UtdOF8 IzLJ1p1krRdSwA/DNtpo4Zt3wETHc+WqFbboqC+WLfZrNP17f6ztcVyEQ8n43uUd HzU15gYgHOUIhMKRmco2AkbpJn2AAyFvck58Xw17BImHgGlXuO9Lheu1qDNMqvA6 EfbZT3lbbpiWKXif5hd0qlORA4gzwAgFLjwMK7Fl1+rV7ZN4ViFOUOOCSJrHKPu7 zozf3XDJ2EXrnh2agsyuqg3Sz8XSphTUAtFp3TITU5rNN6KobGCOM6vYI6pxkPRC ujIOJTP/lYc/rUl8OdjDxGBOxPpjhSMbZbhsztD0bmQ9MF+Pvss= =i0Zr -----END PGP SIGNATURE----- --U1N8xVn0y2CA9aW1--