Loading...
Searching...
No Matches
Data Fields
as_cluster_shm Struct Reference

Detailed Description

Shared memory cluster map. The map contains fixed arrays of nodes and partition tables. Each partition table contains a fixed array of partitions. The shared memory segment will be sized on startup and never change afterwards. If the max nodes or max namespaces are reached, the tender client will ignore additional nodes/namespaces and log an error message that the corresponding array is full.

Definition at line 139 of file as_shm_cluster.h.

+ Collaboration diagram for as_cluster_shm:

Data Fields

uint8_t lock
 
uint32_t n_partitions
 
as_node_shm nodes []
 
uint32_t nodes_capacity
 
uint32_t nodes_gen
 
uint32_t nodes_size
 
uint32_t owner_pid
 
char pad [2]
 
uint32_t partition_table_byte_size
 
uint32_t partition_tables_capacity
 
uint32_t partition_tables_offset
 
uint32_t partition_tables_size
 
uint8_t ready
 
uint32_t rebalance_gen
 
as_spinlock take_over_lock
 
uint64_t timestamp
 

Field Documentation

◆ lock

uint8_t as_cluster_shm::lock

Shared memory master mutex lock. Used to determine cluster tend owner.

Definition at line 198 of file as_shm_cluster.h.

◆ n_partitions

uint32_t as_cluster_shm::n_partitions

Total number of data partitions used by cluster.

Definition at line 168 of file as_shm_cluster.h.

◆ nodes

as_node_shm as_cluster_shm::nodes[]

Definition at line 218 of file as_shm_cluster.h.

◆ nodes_capacity

uint32_t as_cluster_shm::nodes_capacity

Maximum size of nodes array.

Definition at line 158 of file as_shm_cluster.h.

◆ nodes_gen

uint32_t as_cluster_shm::nodes_gen

Nodes generation count. Incremented whenever a node is added or removed from cluster.

Definition at line 163 of file as_shm_cluster.h.

◆ nodes_size

uint32_t as_cluster_shm::nodes_size

Current size of nodes array.

Definition at line 153 of file as_shm_cluster.h.

◆ owner_pid

uint32_t as_cluster_shm::owner_pid

Cluster tend owner process id.

Definition at line 148 of file as_shm_cluster.h.

◆ pad

char as_cluster_shm::pad[2]

Pad to 4 byte boundary.

Definition at line 208 of file as_shm_cluster.h.

◆ partition_table_byte_size

uint32_t as_cluster_shm::partition_table_byte_size

Bytes required to hold one partition_table.

Definition at line 188 of file as_shm_cluster.h.

◆ partition_tables_capacity

uint32_t as_cluster_shm::partition_tables_capacity

Maximum size of partition tables array.

Definition at line 178 of file as_shm_cluster.h.

◆ partition_tables_offset

uint32_t as_cluster_shm::partition_tables_offset

Cluster offset to partition tables at the end of this structure.

Definition at line 183 of file as_shm_cluster.h.

◆ partition_tables_size

uint32_t as_cluster_shm::partition_tables_size

Current size of partition tables array.

Definition at line 173 of file as_shm_cluster.h.

◆ ready

uint8_t as_cluster_shm::ready

Has shared memory been fully initialized and populated.

Definition at line 203 of file as_shm_cluster.h.

◆ rebalance_gen

uint32_t as_cluster_shm::rebalance_gen

Cluster rebalance generation count.

Definition at line 213 of file as_shm_cluster.h.

◆ take_over_lock

as_spinlock as_cluster_shm::take_over_lock

Spin lock for taking over from a dead cluster tender.

Definition at line 193 of file as_shm_cluster.h.

◆ timestamp

uint64_t as_cluster_shm::timestamp

Last time cluster was tended in milliseconds since epoch.

Definition at line 143 of file as_shm_cluster.h.


The documentation for this struct was generated from the following file: