Re: [PATCH] pgbench: add multiconnect option - Mailing list pgsql-hackers

From Jelte Fennema
Subject Re: [PATCH] pgbench: add multiconnect option
Date
Msg-id CAGECzQRYGn7u=VAtqd7dQpnxkoS4k1YGE8VDvd3QvTYUtK-vvw@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] pgbench: add multiconnect option  (Fabien COELHO <coelho@cri.ensmp.fr>)
Responses Re: [PATCH] pgbench: add multiconnect option
List pgsql-hackers
This patch seems to have quite some use case overlap with my patch which adds load balancing to libpq itself: https://www.postgresql.org/message-id/flat/PR3PR83MB04768E2FF04818EEB2179949F7A69@PR3PR83MB0476.EURPRD83.prod.outlook.com

My patch is only able to add "random" load balancing though, not "round-robin". So this patch still definitely seems useful, even when mine gets merged.

I'm not sure that the support for the "working" connection is necessary from a feature perspective though (usability/discoverability is another question). It's already possible to achieve the same behaviour by simply providing multiple host names in the connection string. You can even tell libpq to connect to a primary or secondary by using the target_session_attrs option.

On Fri, 6 Jan 2023 at 11:33, Fabien COELHO <coelho@cri.ensmp.fr> wrote:

Hello Ian,

> cfbot reports the patch no longer applies.  As CommitFest 2022-11 is
> currently underway, this would be an excellent time to update the patch.

Attached a v5 which is just a rebase.

--
Fabien.

pgsql-hackers by date:

Previous
From: tushar
Date:
Subject: Re: Getting an error if we provide --enable-tap-tests switch on SLES 12
Next
From: Dean Rasheed
Date:
Subject: Re: Improve tab completion for ALTER FUNCTION/PROCEDURE/ROUTINE