From dd9a2f1349646018bd1f85ac5725e8653856a932 Mon Sep 17 00:00:00 2001 From: Andrew Durbin Date: Thu, 26 Sep 2024 10:11:21 -0600 Subject: [PATCH] Edge-Node-Cluster: cluster admission additions ZInfoKubeCluster needs a cluster_id which should match the id in config.EdgeNodeCluster.cluster_id Track node entrance into or out of a cluster with KubeNodeInfo.admission_status (NodeAdmission) Signed-off-by: Andrew Durbin --- proto/info/edge_node_cluster.proto | 17 +++++++++++++++++ proto/info/info.proto | 4 ++++ 2 files changed, 21 insertions(+) diff --git a/proto/info/edge_node_cluster.proto b/proto/info/edge_node_cluster.proto index 47292fc..c39f715 100644 --- a/proto/info/edge_node_cluster.proto +++ b/proto/info/edge_node_cluster.proto @@ -29,6 +29,20 @@ message KubeNodeCondition { bool set = 2; } +// Cluster Admission status of the eve node +enum NodeAdmission { + NODE_ADMISSION_UNSPECIFIED = 0; + // Not Clustered is the default state at first boot + NODE_ADMISSION_NOT_CLUSTERED = 1; + // Leaving can be a long lived state due to draining existing data + NODE_ADMISSION_LEAVING = 2; + // Joining can be a long lived state if inter-node networking is not operable + NODE_ADMISSION_JOINING = 3; + // Joined is reached when the node becomes Ready the first time after a request + // to join the cluster + NODE_ADMISSION_JOINED = 4; +} + message KubeNodeInfo { // Name of the node, will match device name string name = 1; @@ -49,6 +63,9 @@ message KubeNodeInfo { string internal_ip = 6; bool schedulable = 7; + + // Admission State of the local node in a cluster + NodeAdmission admission_status = 8; } // StorageHealthStatus is a higher level tracking status to show redundancy/failure-zone level diff --git a/proto/info/info.proto b/proto/info/info.proto index 71360de..b41c706 100644 --- a/proto/info/info.proto +++ b/proto/info/info.proto @@ -1348,4 +1348,8 @@ message ZInfoKubeCluster { // Info message on cluster storage KubeStorageInfo storage = 4; + + // Cluster UUID which will match config.EdgeNodeCluster.cluster_id passed + // in to the node by the controller. + string cluster_id = 5; }