Re: [HACKERS] Full page writes improvement, code update

From: "Simon Riggs" <simon(at)2ndquadrant(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Zeugswetter Andreas ADI SD" <ZeugswetterA(at)spardat(dot)at>, "Koichi Suzuki" <suzuki(dot)koichi(at)oss(dot)ntt(dot)co(dot)jp>, "Hannu Krosing" <hannu(at)skype(dot)net>, "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>, <josh(at)agliodbs(dot)com>, <pgsql-hackers(at)postgresql(dot)org>, <pgsql-patches(at)postgresql(dot)org>
Subject: Re: [HACKERS] Full page writes improvement, code update
Date: 2007-04-13 16:06:08
Message-ID: 1176480368.3635.199.camel@silverbirch.site
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

On Fri, 2007-04-13 at 11:47 -0400, Tom Lane wrote:
> "Simon Riggs" <simon(at)2ndquadrant(dot)com> writes:
> > On Fri, 2007-04-13 at 10:36 -0400, Tom Lane wrote:
> >> That's what bothers me about this patch, too. It will be increasing
> >> the cost of writing WAL (more data -> more CRC computation and more
> >> I/O, not to mention more contention for the WAL locks) which translates
> >> directly to a server slowdown.
>
> > I don't really understand this concern.
>
> The real objection is that a patch that's alleged to make WAL smaller
> actually does the exact opposite. Now maybe you can buy that back
> downstream of the archiver --- after yet more added-on processing ---
> but it still seems that there's a fundamental misdesign here.
>
> > Koichi-san has included a parameter setting that would prevent any
> > change at all in the way WAL is written.
>
> It bothers me that we'd need to have such a switch. That's just another
> way to shoot yourself in the foot, either by not enabling it (in which
> case applying pg_compresslog as it stands would actively break your
> WAL), or by enabling it when you weren't actually going to use
> pg_compresslog (because you misunderstood the documentation to imply
> that it'd make your WAL smaller by itself). What I want to see is a
> patch that doesn't bloat WAL at all and therefore doesn't need a switch.
> I think Andreas is correct to complain that it should be done that way.

I agree with everything you say because we already had *exactly* this
discussion when the patch was already submitted, with me saying
everything you just said.

After a few things have been renamed to show their correct function and
impact, I am now comfortable with this patch.

Writing lots of additional code simply to remove a parameter that
*might* be mis-interpreted doesn't sound useful to me, especially when
bugs may leak in that way. My take is that this is simple and useful
*and* we have it now; other ways don't yet exist, nor will they in time
for 8.3.

--
Simon Riggs
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Trevor Hardcastle 2007-04-13 16:42:51 Re: CREATE TABLE LIKE INCLUDING INDEXES support
Previous Message Tom Lane 2007-04-13 15:47:41 Re: [HACKERS] Full page writes improvement, code update

Browse pgsql-patches by date

  From Date Subject
Next Message Trevor Hardcastle 2007-04-13 16:42:51 Re: CREATE TABLE LIKE INCLUDING INDEXES support
Previous Message Tom Lane 2007-04-13 15:47:41 Re: [HACKERS] Full page writes improvement, code update