Re: walreceiver is uninterruptible on win32

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: walreceiver is uninterruptible on win32
Date: 2010-03-16 01:35:26
Message-ID: 3f0b79eb1003151835g44ab5c16g38b794cd386a8eb9@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Mar 16, 2010 at 12:32 AM, Heikki Linnakangas
<heikki(dot)linnakangas(at)enterprisedb(dot)com> wrote:
>> Something like libpq_select() which waits for the socket to become
>> ready would be required for walreceiver and dblink. But it's necessary
>> for walreceiver on not only win32 but also the other, ...
>
> Really, why? I thought this is a purely Windows specific problem.

Because, on all the platforms, libpq_receive() needs to call libpq_select().
Or you mean that we should leave the existing libpq_select() as it is, and
create new win32 specific function which waits for the socket to become ready,
for this issue?

> Just replacing PQexec() with PQsendQuery() is pretty straightforward, we
> could put that replacement in a file in port/win32. Replacing
> PQconnectdb() is more complicated because you need to handle connection
> timeout. I suggest that we only add the replacement for PQexec(), and
> live with the situation for PQconnectdb(), that covers 99% of the
> scenarios anyway.

I'll try to replace PQexec() first, and PQconnectdb() second if I have
enough time.

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-03-16 01:37:26 Re: Should we throw error when converting a nonexistent/ambiguous timestamp?
Previous Message Robert Haas 2010-03-16 01:22:32 Re: Should we throw error when converting a nonexistent/ambiguous timestamp?