Re: Improvement of procArray.xmin for VACUUM - Mailing list pgsql-patches

From Bruce Momjian
Subject Re: Improvement of procArray.xmin for VACUUM
Date
Msg-id 200703262001.l2QK1fC27346@momjian.us
Whole thread Raw
In response to Re: Improvement of procArray.xmin for VACUUM  ("Simon Riggs" <simon@2ndquadrant.com>)
Responses Re: Improvement of procArray.xmin for VACUUM  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
Simon Riggs wrote:
> On Sat, 2007-03-24 at 11:48 -0400, Tom Lane wrote:
>
> > Also, at some point a long-running transaction becomes a bottleneck
> > simply because its XID is itself the oldest thing visible in the
> > ProcArray and is determining everyone's xmin.  How much daylight is
> > there really between "your xmin is old" and "your xid is old"?
>
> Hmm, yes. How often do we have an LRT that consists of multiple
> statements of significant duration? Not often, I'd wager.
>
> How much does it cost to optimise for this case?

Zero cost.  It involves just tracking if there are any old snapshots,
and if not, update the proc xmin rather than skipping the asignment,
like we do now.

--
  Bruce Momjian  <bruce@momjian.us>          http://momjian.us
  EnterpriseDB                               http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: Improvement of procArray.xmin for VACUUM
Next
From: Tom Lane
Date:
Subject: Re: Improvement of procArray.xmin for VACUUM