Re: xlog location arithmetic - Mailing list pgsql-hackers

From Robert Haas
Subject Re: xlog location arithmetic
Date
Msg-id CA+TgmobFsPgc=tNH-c1ak0jCOF5m=5oanyb7gx1oONv2ipVBmQ@mail.gmail.com
Whole thread Raw
In response to Re: xlog location arithmetic  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: xlog location arithmetic
List pgsql-hackers
On Fri, Mar 9, 2012 at 2:34 PM, Robert Haas <robertmhaas@gmail.com> wrote:
> On Fri, Mar 9, 2012 at 2:26 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Peter Eisentraut <peter_e@gmx.net> writes:
>>>> Yeah, the use of XLogFile to mean something other than, well a file in
>>>> the xlog, is greatly annoying.. I guess we could change it, but it
>>>> goes pretty deep in the system so it's not a small change...
>>
>>> The whole thing was built around the lack of 64 bit integers.  If we bit
>>> the bullet and changed the whole thing to be just a single 64-bit
>>> counter, we could probably delete thousands of lines of code.
>>
>> Hm.  I think "thousands" is an overestimate, but yeah the logic could be
>> greatly simplified.  However, I'm not sure we could avoid breaking the
>> existing naming convention for WAL files.  How much do we care about
>> that?
>
> Probably not very much, since WAL files aren't portable across major
> versions anyway.  But I don't see why you couldn't keep the naming
> convention - there's nothing to prevent you from converting a 64-bit
> integer back into two 32-bit integers if and where needed.

On further reflection, this seems likely to break quite a few
third-party tools.  Maybe it'd be worth it anyway, but it definitely
seems like it would be worth going to at least some minor trouble to
avoid it.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: xlog location arithmetic
Next
From: Robert Haas
Date:
Subject: Re: [v9.2] sepgsql's DROP Permission checks