Re: Add ETIMEDOUT to ALL_CONNECTION_FAILURE_ERRNOS

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Add ETIMEDOUT to ALL_CONNECTION_FAILURE_ERRNOS
Дата
Msg-id 3059801.1633010640@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Add ETIMEDOUT to ALL_CONNECTION_FAILURE_ERRNOS  (Jelte Fennema <Jelte.Fennema@microsoft.com>)
Ответы Re: [EXTERNAL] Re: Add ETIMEDOUT to ALL_CONNECTION_FAILURE_ERRNOS  (Jelte Fennema <Jelte.Fennema@microsoft.com>)
Список pgsql-hackers
Jelte Fennema <Jelte.Fennema@microsoft.com> writes:
> Previously successfully opened TCP connections can still fail on reads
> with ETIMEDOUT. This should be considered a connection failure, so that
> the connection in libpq is marked as CONNECTION_BAD. The reason I got an
> ETIMEDOUT was, because I had set a low tcp_user_timeout in the
> connection string. However, it can probably also happen due to
> keepalive limits being reached.

I'm dubious about the portability of this patch, because we don't
use ETIMEDOUT elsewhere.  strerror.c thinks it may not exist,
which is probably overly conservative because POSIX has required
it since SUSv2.  The bigger problem is that it's not accounted for in
the WSAxxx mapping done in port/win32_port.h and TranslateSocketError.
That'd have to be fixed for this to behave reasonably on Windows,
I think.

            regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Dmitry Dolgov
Дата:
Сообщение: Re: pg_stat_statements and "IN" conditions
Следующее
От: Bharath Rupireddy
Дата:
Сообщение: Re: non-superusers are allowed to drop the replication user, but are not allowed to alter or even create them, is that ok?