Re: pending patch: Re: Streaming replication and pg_xlogfile_name()

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: pending patch: Re: Streaming replication and pg_xlogfile_name()
Дата
Msg-id q2h603c8f071004011022z8ffd0999r3fcffbfa77dd56bf@mail.gmail.com
обсуждение исходный текст
Ответ на pending patch: Re: Streaming replication and pg_xlogfile_name()  (Fujii Masao <masao.fujii@gmail.com>)
Ответы Re: pending patch: Re: Streaming replication and pg_xlogfile_name()
Список pgsql-hackers
On Tue, Mar 30, 2010 at 5:14 AM, Fujii Masao <masao.fujii@gmail.com> wrote:
> On Wed, Mar 3, 2010 at 11:03 PM, Fujii Masao <masao.fujii@gmail.com> wrote:
>> On Tue, Mar 2, 2010 at 10:52 PM, Fujii Masao <masao.fujii@gmail.com> wrote:
>>>> It's not clear what it should return, a TLI corresponding the filename
>>>> of the WAL segment the record was replayed from, so that you can use
>>>> pg_xlogfile_name() to find out the filename of the WAL segment being
>>>> replayed, or the accurate TLI of the record being replayed. I'm leaning
>>>> towards the latter, it feels more correct and accurate, but you could
>>>> argue for the former too. In any case, it needs to be well-defined.
>>>
>>> I agree with you that the latter is more correct and accurate. The simple
>>> fix is updating the lastPageTLI with the CheckPoint->ThisTimeLineID when
>>> replaying the shutdown checkpoint record. Though we might need to use new
>>> variable to keep the last applied timeline instead of the lastPageTLI.
>>
>> Here is the revised patch. I used new local variable instead of lastPageTLI
>> to track the tli of last applied record. It is updated with the tli of the
>> log page header when reading the page, and with the tli of the checkpoint
>> record when replaying the checkpoint shutdown record that changes the tli.
>> So pg_last_xlog_replay_location() can return the accurate tli of the last
>> applied record.
>
> I rebased the patch to HEAD. Should I think that the patch has been rejected
> because it has remained pending for about one month?

Can someone explain to me in plain language what problem this is
trying to fix?  I'm having trouble figuring it out.

...Robert


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: [DOCS] Streaming replication document improvements
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: [GENERAL] Postgres 9.1 - Release Theme