Re: adding a new column in IDENTIFY_SYSTEM

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Jaime Casanova <jaime(at)2ndquadrant(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Simon Riggs <simon(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: adding a new column in IDENTIFY_SYSTEM
Date: 2011-05-25 01:52:38
Message-ID: BANLkTimZ-BQ+9Q2jiFH8Shm=06EyaXx5AA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, May 25, 2011 at 8:26 AM, Jaime Casanova <jaime(at)2ndquadrant(dot)com> wrote:
> On Fri, May 20, 2011 at 12:50 PM, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
>>
>> Yes. It might be useful to note it, and then ust make an override
>> flag. My pointm, though, was that doing it for walreceiver is more
>> important and a more logical first step.
>>
>
> ok, patch attached.

Why is the check of WAL version required for streaming replication?
As Tom said, if the version is different between two servers, the
check of system identifier fails first. No?

+ primary_xlp_magic = atoi(PQgetvalue(res, 0, 2));

You wrongly get the third field (i.e., current xlog location) as the
WAL version.
You should call PQgetvalue(res, 0, 3), instead.

> errdetail("Expected 1 tuple with 3 fields, got %d tuples with %d fields.",

You need to change the above message.

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 Craig Ringer 2011-05-25 01:53:13 Re: Hash Anti Join performance degradation
Previous Message Greg Smith 2011-05-25 01:47:26 Re: 9.2 schedule