Re: Replication server timeout patch

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Replication server timeout patch
Date: 2011-03-30 01:30:48
Message-ID: AANLkTi=vkRGgGzyHso9zM7QNyoCR5z6XwP85Qctu2Spw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Mar 30, 2011 at 1:04 AM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>> COMMERROR exists to keep us from trying to send an error report down a
>> failed socket.  I would assume (perhaps wrongly) that
>> walsender/walreceiver don't try to push error reports across the socket
>> anyway, only to the postmaster log.  If correct, there is no need for
>> COMMERROR, and using it just muddies the code.
>
> I don't think that's how it works.  The error the server sends is
> copied into some of the messages in the client log, which is really
> useful for debugging.
>
> ERROR: can't connect to the server (server said: you're not authorized)
>
> ...or something like that.

Yes. Walsender sends its error message to walreceiver, and walreceiver
writes it down to the server log. For example;

FATAL: could not receive data from WAL stream: FATAL: requested WAL
segment 000000010000000000000016 has already been removed

The second FATAL message is sent from walsender.

Regards,

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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2011-03-30 01:40:00 Re: Triggers on system catalog
Previous Message Andrew Dunstan 2011-03-30 01:30:27 Re: PostgreSQL sourcecode