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 1qAEBv-0001zx-9D for pgsql-general@arkaria.postgresql.org; Fri, 16 Jun 2023 18:28:59 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1qAEBu-0005Ix-6D for pgsql-general@arkaria.postgresql.org; Fri, 16 Jun 2023 18:28:58 +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 1qABm0-0006st-JS for pgsql-general@lists.postgresql.org; Fri, 16 Jun 2023 15:54:04 +0000 Received: from prater.isola.red ([2a0a:4cc0:1:4e:2442::2]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qABlx-002YOR-Q4 for pgsql-general@lists.postgresql.org; Fri, 16 Jun 2023 15:54:03 +0000 Received: from wm.joel-hatsch.net (unknown [172.29.0.3]) (Authenticated sender: michael@weiller.eu) by prater.isola.red (Postfix) with ESMTPSA id 2997AC09FB; Fri, 16 Jun 2023 17:53:59 +0200 (CEST) MIME-Version: 1.0 Date: Fri, 16 Jun 2023 15:53:59 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable From: "Michael Weiller" Message-ID: <86ccf795754997bcc6e8e6a94cf40c8a@weiller.eu> Subject: Re: Question: Multiple pg clusters on one server can be reached with the standard port. To: "Ron" Cc: pgsql-general@lists.postgresql.org In-Reply-To: References: <4d70ad6a5a73b9e9faaf8f2715cac862c86def3c.camel@cybertec.at> <6ba275cd2d442a913a234564aeaec27311ec1d16.camel@cybertec.at> <71943c04e05c3c13d5cd2b287909f351@weiller.eu> <6e8947e1d4394082e27f1f8354ae5d4f@weiller.eu> <507b783267640f0b8dd6b6fdc0f132fa27cb4212.camel@cybertec.at> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk 16. Juni 2023 17:41, "Ron" schrieb: > On 6/16/23 10:18, Laurenz Albe wrote: >=20 >>=20On Fri, 2023-06-16 at 14:49 +0000, Brainmue wrote: >>> 16. Juni 2023 14:50, "Laurenz Albe" schrie= b: >>=20 >>=20On Fri, 2023-06-16 at 12:35 +0000, Brainmue wrote: >>=20 >>=20We want to minimise dependencies between the application and the ass= ociated PostgreSQL DB. >> The idea is that the application gets its DB alias and this is then us= ed as a connection string. >> This way we can decide in the backend on which server the PostgreSQL D= B is running. >> There is an existing solution for that: the libpq connection service f= ile: >> https://www.postgresql.org/docs/current/libpq-pgservice.html >>=20 >>=20If you want to manage the connection strings centrally, you can use = LDAP lookup: >> https://www.postgresql.org/docs/current/libpq-ldap.html >>> Thank you, I already know this solution, but the LDAP solution is out= of the question for us and >>> the file again means an intervention on the client. And that's exactl= y what we don't want. >>=20 >>=20Okay. >>=20 >>=20Then why don't you go with your original solution, but use a unique = TCP port number >> for each database? There are enough port numbers available. That way, = there is no >> collision and no need for a proxy to map port numbers. >=20 >=20In practice, that gets very complicated is large organizations: every= time you add another > database, you must file another request with the CISO RISK office to ge= t yet another non-standard > port open from dozens of machines, and the network team implement them. >=20 >=20Operationally much simpler to have a listener handle that. >=20 >=20-- Born in Arizona, moved to Babylonia. Hello Ron, I have to agree with you there as well. The workflow you have to go throu= gh is also often a time issue. There are many places that have to agree and then application owners stil= l have to provide justifications. At the same time, we have to be flexible and fast and allocate the resour= ces well at any time and provide the application with the maximum possibl= e performance. Regards Michael