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 1ixElD-0006Rf-44 for pgsql-hackers@arkaria.postgresql.org; Thu, 30 Jan 2020 18:41:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1ixElB-0006u8-4w for pgsql-hackers@arkaria.postgresql.org; Thu, 30 Jan 2020 18:41:49 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1ixElA-0006u1-Sg for pgsql-hackers@lists.postgresql.org; Thu, 30 Jan 2020 18:41:48 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ixEl3-0006n4-Ts for pgsql-hackers@postgresql.org; Thu, 30 Jan 2020 18:41:48 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id 00UIfa0G030628; Thu, 30 Jan 2020 13:41:36 -0500 From: Tom Lane To: Peter Eisentraut cc: Andrew Dunstan , pgsql-hackers Subject: Re: Unix-domain socket support on Windows In-reply-to: <3b5fed50-9017-49ca-b556-303a0cc1b660@2ndquadrant.com> References: <54bde68c-d134-4eb8-5bd3-8af33b72a010@2ndquadrant.com> <00d4945e-b437-f3b5-f4af-42e99321c846@2ndquadrant.com> <5974caea-1267-7708-40f2-6009a9d653b0@2ndquadrant.com> <75f72249-8ae6-322a-63df-4fe03eeccb9f@2ndquadrant.com> <3b5fed50-9017-49ca-b556-303a0cc1b660@2ndquadrant.com> Comments: In-reply-to Peter Eisentraut message dated "Thu, 30 Jan 2020 19:28:00 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <30626.1580409696.1@sss.pgh.pa.us> Date: Thu, 30 Jan 2020 13:41:36 -0500 Message-ID: <30627.1580409696@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Peter Eisentraut writes: > On 2019-12-18 14:52, Peter Eisentraut wrote: >> We have code paths for Unix socket support and no Unix socket support. >> Now add a third variant: Unix socket support but do not use a Unix >> socket by default in the client or the server, only if you explicitly >> specify one. >> >> To implement this, tweak things so that setting DEFAULT_PGSOCKET_DIR >> to "" has the desired effect. This mostly already worked like that; >> only a few places needed to be adjusted. Notably, the reference to >> DEFAULT_PGSOCKET_DIR in UNIXSOCK_PATH() could be removed because all >> callers already resolve an empty socket directory setting with a >> default if appropriate. > Perhaps this patch is too boring to be reviewed. If there are no > objections, I'll commit it soon and then submit the final patches with > the real functionality for the next commit fest. Sorry, I'd paid no particular attention to this thread because I figured it'd take a Windows-competent person to review. But the patch as it stands isn't that. The code looks fine (and a big +1 for not having knowledge of DEFAULT_PGSOCKET_DIR wired into UNIXSOCK_PATH). I wonder though whether any user-facing documentation needs to be adjusted. regards, tom lane