1 /*-------------------------------------------------------------------------
2  *
3  * pg_dist_node.h
4  *	  definition of the relation that holds the nodes on the cluster (pg_dist_node).
5  *
6  * Copyright (c) Citus Data, Inc.
7  *
8  *-------------------------------------------------------------------------
9  */
10 
11 #ifndef PG_DIST_NODE_H
12 #define PG_DIST_NODE_H
13 
14 /* ----------------
15  *      compiler constants for pg_dist_node
16  * ----------------
17  *
18  *  n.b. citus_add_node, citus_add_inactive_node, and citus_activate_node all
19  *  directly return pg_dist_node tuples. This means their definitions (and
20  *  in particular their OUT parameters) must be changed whenever the definition of
21  *  pg_dist_node changes.
22  */
23 #define Natts_pg_dist_node 11
24 #define Anum_pg_dist_node_nodeid 1
25 #define Anum_pg_dist_node_groupid 2
26 #define Anum_pg_dist_node_nodename 3
27 #define Anum_pg_dist_node_nodeport 4
28 #define Anum_pg_dist_node_noderack 5
29 #define Anum_pg_dist_node_hasmetadata 6
30 #define Anum_pg_dist_node_isactive 7
31 #define Anum_pg_dist_node_noderole 8
32 #define Anum_pg_dist_node_nodecluster 9
33 #define Anum_pg_dist_node_metadatasynced 10
34 #define Anum_pg_dist_node_shouldhaveshards 11
35 
36 #define GROUPID_SEQUENCE_NAME "pg_dist_groupid_seq"
37 #define NODEID_SEQUENCE_NAME "pg_dist_node_nodeid_seq"
38 
39 #endif /* PG_DIST_NODE_H */
40