Merge pull request 'fix: method name duplicated after client sdk generation' (#1111) from MagicRR/garage:fix-openapi-duplicate-method into main-v2

Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/1111
This commit is contained in:
Alex
2025-08-07 14:32:12 +00:00
3 changed files with 7 additions and 5 deletions

View File

@@ -2443,7 +2443,7 @@
"knownNodes",
"connectedNodes",
"storageNodes",
"storageNodesOk",
"storageNodesUp",
"partitions",
"partitionsQuorum",
"partitionsAllOk"
@@ -2483,7 +2483,7 @@
"description": "the number of storage nodes currently registered in the cluster layout",
"minimum": 0
},
"storageNodesOk": {
"storageNodesUp": {
"type": "integer",
"description": "the number of storage nodes to which a connection is currently open",
"minimum": 0
@@ -4409,4 +4409,4 @@
"bearerAuth": []
}
]
}
}

View File

@@ -258,7 +258,7 @@ pub struct GetClusterHealthResponse {
/// the number of storage nodes currently registered in the cluster layout
pub storage_nodes: usize,
/// the number of storage nodes to which a connection is currently open
pub storage_nodes_ok: usize,
pub storage_nodes_up: usize,
/// the total number of partitions of the data (currently always 256)
pub partitions: usize,
/// the number of partitions for which a quorum of write nodes is available

View File

@@ -134,7 +134,9 @@ impl RequestHandler for GetClusterHealthRequest {
known_nodes: health.known_nodes,
connected_nodes: health.connected_nodes,
storage_nodes: health.storage_nodes,
storage_nodes_ok: health.storage_nodes_ok,
// Translating storage_nodes_up (admin API context) to storage_nodes_ok (metrics context)
// TODO: when releasing major release, consider renaming all the fields in the metrics to storage_nodes_up
storage_nodes_up: health.storage_nodes_ok,
partitions: health.partitions,
partitions_quorum: health.partitions_quorum,
partitions_all_ok: health.partitions_all_ok,