Re: The vacuum-ignore-vacuum patch - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: The vacuum-ignore-vacuum patch
Date
Msg-id 200607281334.k6SDYR012849@momjian.us
Whole thread Raw
In response to Re: The vacuum-ignore-vacuum patch  (Hannu Krosing <hannu@skype.net>)
Responses Re: The vacuum-ignore-vacuum patch  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Hannu Krosing wrote:
> ?hel kenal p?eval, N, 2006-07-27 kell 22:05, kirjutas Bruce Momjian:
> > Another idea Jan had today was whether we could vacuum more rows if a
> > long-running backend is in serializable mode, like pg_dump.
> 
> I don't see how this gives us ability to vacuum more rows, as the
> snapshot of a serializable transaction is the oldest one.

Good question.  Imagine you have a serializable transaction like
pg_dump, and then you have lots of newer transactions.  If pg_dump is
xid=12, and all the new transactions start at xid=30, any row created
and expired between 12 and 30 can be removed because they are not
visible.  For a use case, imagine an UPDATE chain where a rows was
created by x=15 and expired by xid=19.  Right now, we don't remove that
row, though we could.

--  Bruce Momjian   bruce@momjian.us EnterpriseDB    http://www.enterprisedb.com
 + If your life is a hard drive, Christ can be your backup. +


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [PATCHES] pgstattuple extension for indexes
Next
From: Tom Lane
Date:
Subject: Re: The vacuum-ignore-vacuum patch