Re: pg_basebackup --xlog compatibility break

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_basebackup --xlog compatibility break
Date: 2012-05-28 23:50:36
Message-ID: CAHGQGwEBLEzM8=re9=Hxknx9EXUBo305OgFiQeyxkt5ikcwm8A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, May 29, 2012 at 5:38 AM, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
> On Mon, May 28, 2012 at 10:11 PM, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
>> In 9.1, the pg_basebackup option --xlog takes no argument.  In 9.2, it
>> takes a required argument.  I think such compatibility breaks should be
>> avoided, especially in client-side programs.  Now you can't write a
>> script running pg_basebackup that works with 9.1 and 9.2, if you need to
>> include the WAL.
>>
>> I think the behavior of -x/--xlog should be restored to the state of
>> 9.1, and a new option should be added to select between the fetch and
>> stream methods.  (With a suitable default, this would also increase
>> usability a bit.)
>
> Just to be clear - it's not possible to actually accept -x with an
> *optional* parameter, is it? Meaning "-x" would mean the same as "-x
> fetch" and therefor become backwards compatible?
>
> IIRC I did try that, and didn't get it to work - but if that's doable,
> that seems like the cleanest way?

+1 ISTM you need to change getopt_long() to do that.

Regards,

--
Fujii Masao

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Geoghegan 2012-05-29 01:18:54 Uh, I change my mind about commit_delay + commit_siblings (sort of)
Previous Message Tom Lane 2012-05-28 22:37:03 Re: Bogus nestloop rows estimate in 8.4.7