mirror of
https://github.com/postgres/postgres.git
synced 2025-07-07 00:36:50 +03:00
Improve EXPLAIN ANALYZE to show the time spent in each trigger when
executing a statement that fires triggers. Formerly this time was included in "Total runtime" but not otherwise accounted for. As a side benefit, we avoid re-opening relations when firing non-deferred AFTER triggers, because the trigger code can re-use the main executor's ResultRelInfo data structure.
This commit is contained in:
@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/nodes/execnodes.h,v 1.124 2005/03/16 21:38:10 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/nodes/execnodes.h,v 1.125 2005/03/25 21:58:00 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -261,6 +261,7 @@ typedef struct JunkFilter
|
||||
* IndexRelationInfo array of key/attr info for indices
|
||||
* TrigDesc triggers to be fired, if any
|
||||
* TrigFunctions cached lookup info for trigger functions
|
||||
* TrigInstrument optional runtime measurements for triggers
|
||||
* ConstraintExprs array of constraint-checking expr states
|
||||
* junkFilter for removing junk attributes from tuples
|
||||
* ----------------
|
||||
@ -275,6 +276,7 @@ typedef struct ResultRelInfo
|
||||
IndexInfo **ri_IndexRelationInfo;
|
||||
TriggerDesc *ri_TrigDesc;
|
||||
FmgrInfo *ri_TrigFunctions;
|
||||
struct Instrumentation *ri_TrigInstrument;
|
||||
List **ri_ConstraintExprs;
|
||||
JunkFilter *ri_junkFilter;
|
||||
} ResultRelInfo;
|
||||
|
Reference in New Issue
Block a user