X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 79AD7DA0E2 for ; Thu, 6 Oct 2005 10:17:54 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 57206-08 for ; Thu, 6 Oct 2005 13:17:49 +0000 (GMT) Received: from tbmail.tradebot.com (Tradebot-Systems-1096753.cust-rtr.swbell.net [68.90.170.2]) by svr1.postgresql.org (Postfix) with ESMTP id 86CDBD9D29 for ; Thu, 6 Oct 2005 10:17:50 -0300 (ADT) Received: from 192.168.200.29 ([192.168.200.29]) by tbmail.tradebot.com ([192.168.1.50]) with Microsoft Exchange Server HTTP-DAV ; Thu, 6 Oct 2005 13:17:54 +0000 Received: from krb06 by TBMAIL; 06 Oct 2005 08:17:54 -0500 Subject: functions and execution plan caching From: Kelly Burkhart To: pgsql-performance@postgresql.org Content-Type: text/plain Content-Transfer-Encoding: 7bit Date: Thu, 06 Oct 2005 08:17:54 -0500 Message-Id: <1128604674.5421.35.camel@krb06.tradebot.com> Mime-Version: 1.0 X-Mailer: Evolution 2.2.1 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.05 required=5 tests=[AWL=-0.000, FORGED_RCVD_HELO=0.05] X-Spam-Level: X-Archive-Number: 200510/124 X-Sequence-Number: 14892 I am working on a system which will be heavily dependent on functions (some SQL, some PL/pgSQL). I am worried about the backend caching query execution plans for long running connections. Given: - Processes which are connected to the database for long periods of time (transactions are always short). - These processes will use some functions to query data. - Lots of data is being inserted into tables that these functions query. - Vacuums are done frequently. Am I at risk of degrading performance after some time due to stale execution plans? Thanks, -Kelly