Re: pgsql: Split off functions related to timeline history files and XLOG a

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)iki(dot)fi>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Split off functions related to timeline history files and XLOG a
Date: 2012-10-02 18:12:04
Message-ID: CAHGQGwHtdurae1uNTxBJ5jv1BYjgt9mzWpe9thC1SrG-VbQjQw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

On Tue, Oct 2, 2012 at 7:39 PM, Heikki Linnakangas
<heikki(dot)linnakangas(at)iki(dot)fi> wrote:
> Split off functions related to timeline history files and XLOG archiving.
>
> This is just refactoring, to make the functions accessible outside xlog.c.
> A followup patch will make use of that, to allow fetching timeline history
> files over streaming replication.

+ * The files are named like "<WAL segment>.history". For example, if the
+ * database starts up and switches to timeline 5, while processing WAL
+ * segment 000000030000002A00000006 (the old timeline was 3), the timeline
+ * history file would be called "000000050000002A00000006.history".

This comment is incorrect. Correctly the name of the timeline history file is
like "<first eight digits of WAL segment>.history". So in that example,
the timeline history file would be called "00000005.history". Or, are you
planning to change the name of the timeline history file in the followup
patch?

The call of XLogArchiveNotify() for the timeline history file was removed
from writeTimelineHistory(). Why do we need to do this? This change
seems to prevent the timeline history file from being archived at all.

Regards,

--
Fujii Masao

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2012-10-02 19:36:38 pgsql: Standardize naming of malloc/realloc/strdup wrapper functions.
Previous Message Heikki Linnakangas 2012-10-02 17:01:30 Re: pgsql: Silence compiler warning about pointer type mismatch on some pla