Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1gELzc-00012w-Ol for pgsql-general@arkaria.postgresql.org; Sun, 21 Oct 2018 22:14:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gELzZ-0000RP-El for pgsql-general@arkaria.postgresql.org; Sun, 21 Oct 2018 22:14:37 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1gELzZ-0000Qk-38 for pgsql-general@lists.postgresql.org; Sun, 21 Oct 2018 22:14:37 +0000 Received: from n3.nabble.com ([162.255.23.22]) by makus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gELzU-00069m-KA for pgsql-general@postgresql.org; Sun, 21 Oct 2018 22:14:35 +0000 Received: from n3.nabble.com (localhost [127.0.0.1]) by n3.nabble.com (Postfix) with ESMTP id C358BFDA27F3 for ; Sun, 21 Oct 2018 15:14:30 -0700 (MST) Date: Sun, 21 Oct 2018 15:14:30 -0700 (MST) From: legrand legrand To: pgsql-general@postgresql.org Message-ID: <1540160070161-0.post@n3.nabble.com> In-Reply-To: <1538225322173-0.post@n3.nabble.com> References: <1538225322173-0.post@n3.nabble.com> Subject: Re: [proposal] pg_stat_statements: extension timing instrumentation MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk An other way is to use "waits" reporting ... something like : pgss_store (...) pgstat_report_wait_start(PG_WAIT_EXTENSION); ... pgstat_report_wait_end(); gives waits of type "Extension", name "Extension" when spending time in this part of pgss. This can help those working with waits sampling as found in pg_stat_activity, pg_wait_sampling or pgsentinel. note: some of the contentions are already reported as "LWLock" / "pg_stat_statements" Regards PAscal -- Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html