Re: Review of Refactoring code for sync node detection

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>
Cc: Simon Riggs <simon(at)2ndquadrant(dot)com>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, Jim Nasby <Jim(dot)Nasby(at)bluetreble(dot)com>, Jim Nasby <jim(at)nasby(dot)net>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Review of Refactoring code for sync node detection
Date: 2014-12-12 12:50:19
Message-ID: CAB7nPqQnLHy3GPQbLpQeANP27=nn+zPjnYVG-8RAPi_hv_HN7w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Dec 12, 2014 at 9:38 PM, Heikki Linnakangas
<hlinnakangas(at)vmware(dot)com> wrote:
> On 12/12/2014 04:29 AM, Michael Paquier wrote:
>>
>> On Thu, Dec 11, 2014 at 10:07 PM, Heikki Linnakangas <
>> hlinnakangas(at)vmware(dot)com> wrote:
>>
>>> I propose the attached (I admit I haven't tested it).
>>>
>> Actually if you do it this way I think that it would be worth adding the
>> small optimization Fujii-san mentioned upthread: if priority is equal to
>> 1,
>> we leave the loop earlier and return immediately the pointer. All those
>> things gathered give the patch attached, that I actually tested FWIW with
>> multiple standbys and multiple entries in s_s_names.
>
>
> Ok, committed.
Thanks!
--
Michael

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2014-12-12 13:03:44 Re: moving from contrib to bin
Previous Message Heikki Linnakangas 2014-12-12 12:38:31 Re: Review of Refactoring code for sync node detection