Re: Hot Standby query cancellation and Streaming Replication integration - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: Hot Standby query cancellation and Streaming Replication integration
Date
Msg-id 1267394331.20134.3114.camel@ebony
Whole thread Raw
In response to Re: Hot Standby query cancellation and Streaming Replication integration  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Fri, 2010-02-26 at 16:44 -0500, Tom Lane wrote:
> Greg Stark <gsstark@mit.edu> writes:
> > On Fri, Feb 26, 2010 at 9:19 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> >> There's *definitely* not going to be enough information in the WAL
> >> stream coming from a master that doesn't think it has HS slaves.
> >> We can't afford to record all that extra stuff in installations for
> >> which it's just useless overhead. BTW, has anyone made any attempt
> >> to measure the performance hit that the patch in its current form is
> >> creating via added WAL entries?
> 
> > What extra entries?
> 
> Locks, just for starters.  I haven't read enough of the code yet to know
> what else Simon added.  In the past it's not been necessary to record
> any transient information in WAL, but now we'll have to.

There is room for technical confusion here, so I'll just add some info.

There was/is potential for performance hit because of the volume of
additional WAL *and* the processing overhead from that additional WAL.
As Heikki points out these turn out to be minimal, though this has been
by careful design.

There is also potential for a performance hit because incoming cleanup
records may conflict with currently executing queries. If we knew for
certain that the master was not sending any cleanup records that would
effect current standby queries we could avoid that overhead altogether.
That's a good reason for integrating a solution.

AccessExclusiveLock lock records are nothing at all to do with that.
They exist simply to prevent obvious correctness issues such as somebody
reading a file while it is being deleted.

-- Simon Riggs           www.2ndQuadrant.com



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: remove contrib/xml2
Next
From: Simon Riggs
Date:
Subject: Re: Hot Standby query cancellation and Streaming Replication integration