Re: [PATCHES] GIN improvements
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Jeff Davis <pgsql@j-davis.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Teodor Sigaev <teodor@sigaev.ru>, Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>, Pgsql Hackers <pgsql-hackers@postgresql.org>
Date: 2009-02-04T21:49:37Z
Lists: pgsql-hackers
On Wed, Feb 4, 2009 at 4:23 PM, Jeff Davis <pgsql@j-davis.com> wrote: > On Wed, 2009-02-04 at 14:40 -0500, Robert Haas wrote: >> Well, there's nothing to force that plan to be invalidated when the >> state of the pending list changes, is there? >> > > Would it be unreasonable to invalidate cached plans during the pending > list cleanup? > > Anyway, it just strikes me as strange to expect a plan to be a good plan > for very long. Can you think of an example where we applied this rule > before? Well, I am not an expert on this topic. But, plans for prepared statements and statements within PL/pgsql functions are cached for the lifetime of the session, which in some situations could be quite long. I would think that invalidating significantly more often would be bad for performance. ...Robert