1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-25 13:17:41 +03:00
Files
postgres/src/include/access/rmgr.h
Andres Freund 728f152e07 Add rmgr callback to name xlog record types for display purposes.
This is primarily useful for the upcoming pg_xlogdump --stats feature,
but also allows to remove some duplicated code in the rmgr_desc
routines.

Due to the separation and harmonization, the output of dipsplayed
records changes somewhat. But since this isn't enduser oriented
content that's ok.

It's potentially desirable to further change pg_xlogdump's display of
records. It previously wasn't possible to show the record type
separately from the description forcing it to be in the last
column. But that's better done in a separate commit.

Author: Abhijit Menon-Sen, slightly editorialized by me
Reviewed-By: Álvaro Herrera, Andres Freund, and Heikki Linnakangas
Discussion: 20140604104716.GA3989@toroid.org
2014-09-19 16:20:29 +02:00

36 lines
609 B
C

/*
* rmgr.h
*
* Resource managers definition
*
* src/include/access/rmgr.h
*/
#ifndef RMGR_H
#define RMGR_H
typedef uint8 RmgrId;
/*
* Built-in resource managers
*
* The actual numerical values for each rmgr ID are defined by the order
* of entries in rmgrlist.h.
*
* Note: RM_MAX_ID must fit in RmgrId; widening that type will affect the XLOG
* file format.
*/
#define PG_RMGR(symname,name,redo,desc,identify,startup,cleanup) \
symname,
typedef enum RmgrIds
{
#include "access/rmgrlist.h"
RM_NEXT_ID
} RmgrIds;
#undef PG_RMGR
#define RM_MAX_ID (RM_NEXT_ID - 1)
#endif /* RMGR_H */