Re: Cached Query Plans (was: global prepared statements) - Mailing list pgsql-hackers

From Jonah H. Harris
Subject Re: Cached Query Plans (was: global prepared statements)
Date
Msg-id 36e682920804122121y4bf44dbeg53f62fc52316fa81@mail.gmail.com
Whole thread Raw
In response to Re: Cached Query Plans (was: global prepared statements)  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Cached Query Plans (was: global prepared statements)
List pgsql-hackers
On Sat, Apr 12, 2008 at 10:17 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>  > Yes, this is worthless on large active databases.  The logging
>  > overhead alone starts to affect performance.
>
>  But somehow, all that stuff with cached plans is free?

Of course not.  The first time you execute a query, it is cached... so
you pay the same penalty you do in PG, but in many cases, only once.
In regards to plan re-use, sure there's going to be some contention on
the hash buckets... but that can be mitigated in a lot of ways.

In addition to that, Oracle collects over two thousand other
statistics in real-time... yet somehow Oracle is quite fast.  So, I
would say that the usual complaint about collecting stats should be
more an issue of proper implementation than a complaint about the act
of collection itself.

-- 
Jonah H. Harris, Sr. Software Architect | phone: 732.331.1324
EnterpriseDB Corporation | fax: 732.331.1301
499 Thornall Street, 2nd Floor | jonah.harris@enterprisedb.com
Edison, NJ 08837 | http://www.enterprisedb.com/


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Re: [COMMITTERS] pgsql: Strengthen warnings about using pg_dump's -i option.
Next
From: "Joshua D. Drake"
Date:
Subject: Re: Re: [COMMITTERS] pgsql: Strengthen warnings about using pg_dump's -i option.