Internal catalogs and views v6.3.0
Catalogs and views are listed here in alphabetical order.
bdr.autopartition_partitions
An internal catalog table that stores information about the partitions created by the autopartitioning feature.
bdr.autopartition_partitions columns
| Name | Type | Description |
|---|---|---|
| ap_parent_relid | oid | OID for relation |
| ap_part_relname | name | Name of created relation |
| ap_part_created_at | timestamp with time zone | Creation timestamp |
| ap_part_migrated_at | timestamp with time zone | Migration timestamp |
| ap_part_dropped_at | timestamp with time zone | Timestamp when dropped |
bdr.autopartition_rules
An internal catalog table that stores information about the autopartitioning rules.
bdr.autopartition_rules columns
| Name | Type | Description |
|---|---|---|
| ap_partition_relid | oid | |
| ap_partition_relname | name | |
| ap_partition_schemaname | name | |
| ap_partition_increment_kind | "char" | |
| ap_secondary_tablespace | oid | |
| ap_maximum_advance_partitions | integer | |
| ap_is_autoscaled | boolean | |
| ap_latest_partitions | integer | |
| ap_enabled | boolean | |
| ap_migrate_after_period | interval | |
| ap_data_retention_period | interval | |
| ap_last_triggered | timestamp with time zone | |
| ap_partition_increment_value | text | |
| ap_partition_autocreate_expr | text | |
| ap_partition_initial_lowerbound | text | |
| ap_partition_last_upperbound | text | |
| ap_partition_min_upperbound | text |
bdr.ddl_epoch
An internal catalog table holding state per DDL epoch.
bdr.ddl_epoch columns
| Name | Type | Description |
|---|---|---|
| ddl_epoch | int8 | Monotonically increasing epoch number |
| origin_node_id | oid | Internal node ID of the node that requested creation of this epoch |
| epoch_consume_timeout | timestamptz | Timeout of this epoch |
| epoch_consumed | boolean | Switches to true as soon as the local node has fully processed the epoch |
| epoch_consumed_lsn | boolean | LSN at which the local node has processed the epoch |
bdr.event_history
Internal catalog table that tracks cluster membership events for a given PGD node. Specifically, it tracks:
- Node joins (to the cluster)
- Raft state changes (that is, whenever the node changes its role in the consensus protocol - leader, follower, or candidate to leader); see Monitoring Raft consensus
- Whenever a worker has errored out (see bdr.workers and Monitoring PGD replication workers)
bdr.event_history columns
| Name | Type | Description |
|---|---|---|
| event_node_id | oid | ID of the node to which the event refers |
| event_type | int | Type of the event (a node, raft, or worker-related event) |
| event_sub_type | int | Subtype of the event, that is, if it's a join, a state change, or an error |
| event_source | text | Name of the worker process where the event was sourced |
| event_time | timestamptz | Timestamp at which the event occurred |
| event_text | text | Textual representation of the event (for example, the error of the worker) |
| event_detail | text | A more detailed description of the event (for now, only relevant for worker errors) |
bdr.event_summary
A view of the bdr.event_history catalog that displays the information in a more
human-friendly format. Specifically, it displays the event types and subtypes
as textual representations rather than integers.
bdr.local_leader_change
This is a local cache of the recent portion of leader change history. It has the same fields as bdr.leader, except that it is an ordered set of (node_group_id, leader_kind, generation) instead of a map tracking merely the current version.
bdr.node_config
An internal catalog table with per-node configuration options.
bdr.node_config columns
| Name | Type | Description |
|---|---|---|
| node_id | oid | Node ID |
| node_route_priority | int | Priority assigned to this node |
| node_route_fence | boolean | Switch to fence this node |
| node_route_writes | boolean | Switch to allow writes |
| node_route_reads | boolean | Switch to allow reads |
| node_route_dsn | text | Interface of this node |
bdr.node_config_summary
A view of the bdr.node_config catalog that displays the information in a more human-readable format.
bdr.node_config_summary columns
| Name | Type | Description |
|---|---|---|
| node_name | text | The name of this node |
| node_id | oid | Node ID |
| node_route_priority | int | Priority assigned to this node |
| node_route_fence | boolean | Switch to fence this node |
| node_route_writes | boolean | Switch to allow writes |
| node_route_reads | boolean | Switch to allow reads |
| node_route_dsn | text | Interface of this node |
| effective_route_dsn | text | Full DSN of this node |
bdr.node_group_config
An internal catalog table with per-node group configuration options.
bdr.node_group_config columns
| Name | Type | Description |
|---|---|---|
| node_group_id | oid | Node group ID. |
| route_writer_max_lag | bigint | Maximum write lag accepted. |
| route_reader_max_lag | bigint | Maximum read lag accepted. |
| route_writer_wait_flush | boolean | Switch if we need to wait for the flush. |
| leader_progress_tracking_enable | boolean | Enables periodic replication progress reports on each data nodes to the Raft leader. These reports ensure the most up-to-date node is selected during write leader elections. Defaults to true. |
| leader_progress_tracking_period | interval | The frequency at which replication progress reports are sent to the Raft leader. Defaults to 1s. |
bdr.node_group_routing_config_summary
Per-node-group routing configuration options.
bdr.node_group_routing_config_summary columns
| Name | Type | Description |
|---|---|---|
| node_group_name | name | Node group name |
| location | name | Node group location |
| enable_routing | boolean | Group routing enabled? |
| node_group_type | text | Node group type (one of "global", "data", or "subscriber-only") |
| route_writer_max_lag | bigint | Maximum write lag accepted |
| route_reader_max_lag | bigint | Maximum read lag accepted |
| route_writer_wait_flush | boolean | Wait for flush |
bdr.node_group_routing_info
An internal catalog table holding current routing information for connection manager.
bdr.node_group_routing_info columns
| Name | Type | Description |
|---|---|---|
| node_group_id | oid | Node group ID. |
| write_node_id | oid | Current write node. |
| prev_write_node_id | oid | Previous write node. |
| read_node_ids | oid[] | List of read-only nodes IDs. |
| record_version | bigint | Record version. Incremented by 1 on every material change to the routing record. |
| record_ts | timestamptz | Timestamp of last update to record_version. |
| write_leader_version | bigint | Write leader version. Copied from record_version every time write_node_id is changed. |
| write_leader_ts | timestamptz | Write leader timestamp. Copied from record_ts every time write_node_id is changed. |
| read_nodes_version | bigint | Read nodes version. Copied from record_version every time read_node_ids list is changed. |
| read_nodes_ts | timestamptz | Read nodes timestamp. Copied from record_tw every time read_node_ids list is changed. |
bdr.node_group_routing_summary
A view of bdr.node_group_routing_info catalog that shows the information in more friendly way.
bdr.node_group_routing_summary columns
| Name | Type | Description |
|---|---|---|
| node_group_name | name | Node group name |
| write_lead | name | Current write lead |
| previous_write_lead | name | Previous write lead |
| read_nodes | name[] | Current read-only nodes |
bdr.node_peer_progress_mapping
A internal catalog used to track the relative progress of each node in the cluster against each other node to assist with group slot movement.
This is an internal relation used by PGD to assist with node progress tracking. Its contents are primarily for system use and should not be used as a standalone reference to infer the exact state or health of replication progress.
bdr.node_peer_progress_mapping columns
| Name | Type | Description |
|---|---|---|
| peer_node_id | oid | OID of the remote peer node for which this progress information was reported. |
| local_lsn | pg_lsn | LSN on the local node at the time the progress was recorded. |
| remote_lsn | pg_lsn | LSN on the originating node at the time the progress was reported. |
bdr.node_routing_config_summary
A friendly view of the per-node routing configuration options. Shows the node name rather than the oid and shorter field names.
bdr.node_routing_config_summary columns
| Name | Type | Description |
|---|---|---|
| gid | name | Node name |
| route_priority | int | Priority assigned to this node |
| route_fence | boolean | Switch to fence this node |
| route_writes | boolean | Switch to allow writes |
| route_reads | boolean | Switch to allow reads |
| route_dsn | text | Interface of this node |
bdr.prepared_xacts_summary
An internal local node view that provides diagnostic information for prepared transactions implicitly created by an origin node when using group commit scopes.
bdr.prepared_xacts_summary columns
| Name | Type | Description |
|---|---|---|
| gid | name | Global identifier of the implicitly prepared transaction. |
| origin_node_id | oid | OID of the node where the transaction originated. |
| origin_xid | xid | Transaction ID of the prepared transaction on the origin node. |
| origin_name | name | Name of the origin node. |
| commit_scope_name | name | Name of the commit scope used for the transaction. |
| origin_node_group | name | Name of the node group associated with the origin node group for the commit scope. |
| cs_id | oid | Internal ID of the commit scope. |
| transaction_state | name | Current state of the prepared transaction. For example, waiting for prepared confirmation. |
| local_prepared_ts | timestamp with time zone | Timestamp when the transaction was prepared on the local node. |
| local_xid | xid | Transaction ID of the corresponding prepared transaction on the local node. |
| pid | int | PID of the process handling the prepared transaction, if active. |
| decision | char | The commit decision for the prepared transaction, if reached. |
bdr.reconcile_2pc_requests
An internal state table storing the current state of 2 phase commit reconciliation requests. The view bdr.reconcile_2pc_requests_summary provides a human-readable representation of this table.
bdr.reconcile_2pc_requests columns
| Name | Type | Description |
|---|---|---|
| origin_id | oid | OID of the origin node for which the reconciliation request was created. |
| coord_id | oid | OID of the coordinator node acting as the reconciler. Remains empty until a coordinator is elected. |
| reconcile_status | integer | Status code of the reconciliation request. |
| origin_lsn | pg_lsn | LSN of the origin node as seen by the coordinator at the time of assignment. Remains empty until a coordinator is elected. |
| origin_commit_ts | timestamptz | Commit timestamp of the origin known to the coordinator at the time of assignment. Remains empty until a coordinator is elected. |
| reconcile_request_ts | timestamptz | The timestamp when the reconciliation request was registered for the origin ID. |
bdr.reconcile_2pc_requests_summary
A view providing a human-readable summary of the reconciliation requests stored in bdr.reconcile_2pc_requests.
bdr.reconcile_2pc_requests_summary columns
| Name | Type | Description |
|---|---|---|
| origin | text | Name of the origin node for which the reconciliation request was created. |
| coordinator | text | Name of the coordinator node performing the reconciliation. Remains empty until a coordinator is elected. |
| origin_commit_ts | timestamptz | Commit timestamp of the origin known to the coordinator at the time of assignment. |
| origin_lsn | pg_lsn | LSN of the origin node as seen by the coordinator at the time of assignment. Remains empty until a coordinator is elected. |
| reconcile_request_ts | timestamptz | The timestamp when the reconciliation request was registered for the origin. Remains empty until a coordinator is elected. |
| reconcile_status | text | Textual status of the reconciliation request. For example: leader elect, start, done, failed. |
bdr.sequence_kind
An internal state table storing the type of each non-local sequence. We recommend the view
bdr.sequences for diagnostic purposes.
bdr.sequence_kind columns
| Name | Type | Description |
|---|---|---|
| seqid | oid | Internal OID of the sequence |
| seqkind | char | Internal sequence kind (l=local,t=timeshard,s=snowflakeid,g=galloc) |
| sequuid | name | Global identifier for the sequence. |
bdr.sync_node_requests
An internal state table storing the state of node synchronization requests. The view
bdr.sync_node_requests_summary
provides a human-readable representation of this table.
bdr.sync_node_requests columns
| Name | Type | Description |
|---|---|---|
| sn_origin_node_id | oid | Unavailable node with changes to be synchronized |
| sn_target_node_id | oid | Node with the origin node's changes |
| sn_source_node_id | oid | Target node for the sync request |
| sn_sync_start_lsn | pg_lsn | Start LSN of the sync request |
| sn_sync_start_ts | timestamptz | Start timestamp of the sync request |
| sn_sync_end_lsn | pg_lsn | End LSN of the sync request |
| sn_sync_end_ts | timestamptz | End timestamp of the sync request |
| sn_sync_status | text | Status of the sync request |
bdr.sync_node_requests_summary
A view providing a human-readable version of the underlying bdr.sync_node_requests
table.
bdr.sync_node_requests_summary columns
| Name | Type | Description |
|---|---|---|
| origin | text | Unavailable node with changes to be synchronized |
| source | text | Node with the origin node's changes |
| target | text | Target node for the sync request |
| sync_start_lsn | pg_lsn | Start LSN of the sync request |
| sync_start_ts | timestamptz | Start timestamp of the sync request |
| sync_end_lsn | pg_lsn | End LSN of the sync request |
| sync_end_ts | timestamptz | End timestamp of the sync request |
| sync_status | text | Status of the sync request |
- On this page
- bdr.autopartition_partitions
- bdr.autopartition_rules
- bdr.ddl_epoch
- bdr.event_history
- bdr.event_summary
- bdr.local_leader_change
- bdr.node_config
- bdr.node_config_summary
- bdr.node_group_config
- bdr.node_group_routing_config_summary
- bdr.node_group_routing_info
- bdr.node_group_routing_summary
- bdr.node_peer_progress_mapping
- bdr.node_routing_config_summary
- bdr.prepared_xacts_summary
- bdr.reconcile_2pc_requests
- bdr.reconcile_2pc_requests_summary
- bdr.sequence_kind
- bdr.sync_node_requests
- bdr.sync_node_requests_summary