aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/xact.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/transam/xact.c')
-rw-r--r--src/backend/access/transam/xact.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/backend/access/transam/xact.c b/src/backend/access/transam/xact.c
index 9e048deba6b..293980ea511 100644
--- a/src/backend/access/transam/xact.c
+++ b/src/backend/access/transam/xact.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.103 2001/06/19 19:42:15 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.104 2001/06/22 19:16:21 wieck Exp $
*
* NOTES
* Transaction aborts can now occur two ways:
@@ -176,6 +176,8 @@
#include "utils/relcache.h"
#include "utils/temprel.h"
+#include "pgstat.h"
+
extern bool SharedBufferChanged;
static void AbortTransaction(void);
@@ -1083,6 +1085,9 @@ CommitTransaction(void)
SharedBufferChanged = false;/* safest place to do it */
+ /* Count transaction commit in statistics collector */
+ pgstat_count_xact_commit();
+
/*
* done with commit processing, set current transaction state back to
* default
@@ -1163,6 +1168,9 @@ AbortTransaction(void)
AtEOXact_portals();
RecordTransactionAbort();
+ /* Count transaction abort in statistics collector */
+ pgstat_count_xact_rollback();
+
RelationPurgeLocalRelation(false);
AtEOXact_temp_relations(false);
smgrDoPendingDeletes(false);