PostgreSQL Source Code  git master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
pg_replication_origin.h
Go to the documentation of this file.
1 /*-------------------------------------------------------------------------
2  *
3  * pg_replication_origin.h
4  * Persistent replication origin registry
5  *
6  * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
7  * Portions Copyright (c) 1994, Regents of the University of California
8  *
9  * src/include/catalog/pg_replication_origin.h
10  *
11  * NOTES
12  * the genbki.pl script reads this file and generates .bki
13  * information from the DATA() statements.
14  *
15  *-------------------------------------------------------------------------
16  */
17 #ifndef PG_REPLICATION_ORIGIN_H
18 #define PG_REPLICATION_ORIGIN_H
19 
20 #include "catalog/genbki.h"
21 #include "access/xlogdefs.h"
22 
23 /* ----------------
24  * pg_replication_origin. cpp turns this into
25  * typedef struct FormData_pg_replication_origin
26  * ----------------
27  */
28 #define ReplicationOriginRelationId 6000
29 
30 CATALOG(pg_replication_origin,6000) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
31 {
32  /*
33  * Locally known id that get included into WAL.
34  *
35  * This should never leave the system.
36  *
37  * Needs to fit into an uint16, so we don't waste too much space in WAL
38  * records. For this reason we don't use a normal Oid column here, since
39  * we need to handle allocation of new values manually.
40  */
41  Oid roident;
42 
43  /*
44  * Variable-length fields start here, but we allow direct access to
45  * roname.
46  */
47 
48  /* external, free-format, name */
49  text roname BKI_FORCE_NOT_NULL;
50 
51 #ifdef CATALOG_VARLEN /* further variable-length fields */
52 #endif
54 
56 
57 /* ----------------
58  * compiler constants for pg_replication_origin
59  * ----------------
60  */
61 #define Natts_pg_replication_origin 2
62 #define Anum_pg_replication_origin_roident 1
63 #define Anum_pg_replication_origin_roname 2
64 
65 /* ----------------
66  * pg_replication_origin has no initial contents
67  * ----------------
68  */
69 
70 #endif /* PG_REPLICATION_ORIGIN_H */
FormData_pg_replication_origin
CATALOG(pg_replication_origin, 6000) BKI_SHARED_RELATION BKI_WITHOUT_OIDS
#define BKI_SHARED_RELATION
Definition: genbki.h:27
unsigned int Oid
Definition: postgres_ext.h:31
#define BKI_WITHOUT_OIDS
Definition: genbki.h:28
#define BKI_FORCE_NOT_NULL
Definition: genbki.h:32
FormData_pg_replication_origin * Form_pg_replication_origin
Definition: c.h:434