Re: libpq async connection and multiple hosts

From: Daniele Varrazzo <daniele(dot)varrazzo(at)gmail(dot)com>
To: Jelte Fennema <postgres(at)jeltef(dot)nl>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: libpq async connection and multiple hosts
Date: 2023-10-25 16:54:15
Message-ID: CA+mi_8aAL=a6SM+UTsce=s_9DWOjsH1fwcqFLkbwRKd+oNr0Pw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 25 Oct 2023 at 17:35, Jelte Fennema <postgres(at)jeltef(dot)nl> wrote:

> You should implement load_balance_hosts=random though
> by randomizing your hosts list.

Good catch. So it seems that, if someone wants to build an equivalent
an async version of PQconnectdb, they need to handle on their own:

- connect_timeout
- multiple host, hostaddr, port
- load_balance_hosts=random

Does this list sound complete?

-- Daniele

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniele Varrazzo 2023-10-25 16:58:10 Re: libpq async connection and multiple hosts
Previous Message Nathan Bossart 2023-10-25 15:43:25 Re: CRC32C Parallel Computation Optimization on ARM