Header And Logo

PostgreSQL
| The world's most advanced open source database.

twophase_rmgr.c

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * twophase_rmgr.c
00004  *    Two-phase-commit resource managers tables
00005  *
00006  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00007  * Portions Copyright (c) 1994, Regents of the University of California
00008  *
00009  *
00010  * IDENTIFICATION
00011  *    src/backend/access/transam/twophase_rmgr.c
00012  *
00013  *-------------------------------------------------------------------------
00014  */
00015 #include "postgres.h"
00016 
00017 #include "access/multixact.h"
00018 #include "access/twophase_rmgr.h"
00019 #include "pgstat.h"
00020 #include "storage/lock.h"
00021 #include "storage/predicate.h"
00022 
00023 
00024 const TwoPhaseCallback twophase_recover_callbacks[TWOPHASE_RM_MAX_ID + 1] =
00025 {
00026     NULL,                       /* END ID */
00027     lock_twophase_recover,      /* Lock */
00028     NULL,                       /* pgstat */
00029     multixact_twophase_recover, /* MultiXact */
00030     predicatelock_twophase_recover      /* PredicateLock */
00031 };
00032 
00033 const TwoPhaseCallback twophase_postcommit_callbacks[TWOPHASE_RM_MAX_ID + 1] =
00034 {
00035     NULL,                       /* END ID */
00036     lock_twophase_postcommit,   /* Lock */
00037     pgstat_twophase_postcommit, /* pgstat */
00038     multixact_twophase_postcommit,      /* MultiXact */
00039     NULL                        /* PredicateLock */
00040 };
00041 
00042 const TwoPhaseCallback twophase_postabort_callbacks[TWOPHASE_RM_MAX_ID + 1] =
00043 {
00044     NULL,                       /* END ID */
00045     lock_twophase_postabort,    /* Lock */
00046     pgstat_twophase_postabort,  /* pgstat */
00047     multixact_twophase_postabort,       /* MultiXact */
00048     NULL                        /* PredicateLock */
00049 };
00050 
00051 const TwoPhaseCallback twophase_standby_recover_callbacks[TWOPHASE_RM_MAX_ID + 1] =
00052 {
00053     NULL,                       /* END ID */
00054     lock_twophase_standby_recover,      /* Lock */
00055     NULL,                       /* pgstat */
00056     NULL,                       /* MultiXact */
00057     NULL                        /* PredicateLock */
00058 };