![]() |
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 145 of file as_shm_cluster.h.
Data Fields | |
as_node_shm | nodes [] |
Private Attributes | |
uint8_t | lock |
uint32_t | n_partitions |
uint32_t | nodes_capacity |
uint32_t | nodes_gen |
uint32_t | nodes_size |
uint32_t | owner_pid |
char | pad [6] |
uint32_t | partition_table_byte_size |
uint32_t | partition_tables_capacity |
uint32_t | partition_tables_offset |
uint32_t | partition_tables_size |
uint8_t | ready |
ck_spinlock_t | take_over_lock |
uint64_t | timestamp |
|
private |
Shared memory master mutex lock. Used to determine cluster tend owner.
Definition at line 216 of file as_shm_cluster.h.
|
private |
Total number of data partitions used by cluster.
Definition at line 180 of file as_shm_cluster.h.
as_node_shm as_cluster_shm::nodes[] |
Definition at line 234 of file as_shm_cluster.h.
|
private |
Maximum size of nodes array.
Definition at line 168 of file as_shm_cluster.h.
|
private |
Nodes generation count. Incremented whenever a node is added or removed from cluster.
Definition at line 174 of file as_shm_cluster.h.
|
private |
Current size of nodes array.
Definition at line 162 of file as_shm_cluster.h.
|
private |
Cluster tend owner process id.
Definition at line 156 of file as_shm_cluster.h.
|
private |
Pad to 8 byte boundary.
Definition at line 228 of file as_shm_cluster.h.
|
private |
Bytes required to hold one partition_table.
Definition at line 204 of file as_shm_cluster.h.
|
private |
Maximum size of partition tables array.
Definition at line 192 of file as_shm_cluster.h.
|
private |
Cluster offset to partition tables at the end of this structure.
Definition at line 198 of file as_shm_cluster.h.
|
private |
Current size of partition tables array.
Definition at line 186 of file as_shm_cluster.h.
|
private |
Has shared memory been fully initialized and populated.
Definition at line 222 of file as_shm_cluster.h.
|
private |
Spin lock for taking over from a dead cluster tender.
Definition at line 210 of file as_shm_cluster.h.
|
private |
Last time cluster was tended in milliseconds since epoch.
Definition at line 150 of file as_shm_cluster.h.