Re: WAL-based allocation of XIDs is insecure - Mailing list pgsql-hackers

From Vadim Mikheev
Subject Re: WAL-based allocation of XIDs is insecure
Date
Msg-id 056001c0a6fc$29e7cb40$4879583f@sectorbase.com
Whole thread Raw
In response to WAL-based allocation of XIDs is insecure  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> On third thought --- we could still log the original page contents and
> the modification log record atomically, if what were logged in the xlog
> record were (essentially) the parameters to the operation being logged,
> not its results. That is, make the log entry before you start doing the
> mod work, not after. This might also simplify redo, since redo would be
> no different from the normal case. I'm not sure why Vadim didn't choose
> to do it that way; maybe there's some other fine point I'm missing.

There is one - indices over user defined data types: catalog is not
available at the time of recovery, so, eg, we can't know how to order
keys of "non-standard" types. (This is also why we have to recover
aborted index split ops at runtime, when catalog is already available.)

Also, there is no point why should we log original page content and
the next modification record separately.

Vadim




pgsql-hackers by date:

Previous
From: "Vadim Mikheev"
Date:
Subject: Re: WAL-based allocation of XIDs is insecure
Next
From: Zeugswetter Andreas SB
Date:
Subject: AW: WAL-based allocation of XIDs is insecure