Re: CSStorm occurred again by postgreSQL8.2 - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: CSStorm occurred again by postgreSQL8.2
Date
Msg-id 20060807185243.GB26021@alvh.no-ip.org
Whole thread Raw
In response to Re: CSStorm occurred again by postgreSQL8.2  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: CSStorm occurred again by postgreSQL8.2
List pgsql-hackers
Tom Lane wrote:

> I'm wondering about doing something similar to what
> TransactionIdIsInProgress does, ie, make use of the PGPROC lists
> of live subtransactions.  Suppose that GetSnapshotData copies not
> only top xids but live subxids into the snapshot, and adds a flag
> indicating whether the subxids are complete (ie, none of the subxid
> lists have overflowed).  Then if the flag is set, tqual.c doesn't
> need to do SubTransGetTopmostTransaction() before searching the
> list.

Well, that sounds awfully more expensive than setting
local-to-my-database Xmins as well as global (all databases) Xmins :-)

On the other hand, ISTM as soon as one cache overflows, you have to go
check pg_subtrans which means the entire optimization buys nothing in
that case.  It would be nice if the optimization degraded more
gracefully.  I don't have any concrete suggestion though.  The changes
proposed in the other CS-storm thread by the NTT person may help.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: buildfarm - make check failures for leveret on 8.0
Next
From: Jeremy Drake
Date:
Subject: Re: buildfarm - make check failures for leveret on 8.0