From a20a0e5c6331287b9ee104aee467a0e328844ece Mon Sep 17 00:00:00 2001 From: Kyle Liberti Date: Wed, 11 Jun 2025 14:48:22 -0400 Subject: [PATCH] Add documentation for tracking progress of Cruise Control rebalances Signed-off-by: Kyle Liberti --- .../assembly-cruise-control-concepts.adoc | 2 + .../proc-tracking-cluster-rebalance.adoc | 47 +++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 documentation/modules/cruise-control/proc-tracking-cluster-rebalance.adoc diff --git a/documentation/assemblies/cruise-control/assembly-cruise-control-concepts.adoc b/documentation/assemblies/cruise-control/assembly-cruise-control-concepts.adoc index 984f84cae7a..418d9c3f0b3 100644 --- a/documentation/assemblies/cruise-control/assembly-cruise-control-concepts.adoc +++ b/documentation/assemblies/cruise-control/assembly-cruise-control-concepts.adoc @@ -34,3 +34,5 @@ include::../../modules/cruise-control/proc-approving-optimization-proposal.adoc[ include::../../modules/cruise-control/proc-stopping-cluster-rebalance.adoc[leveloffset=+1] include::../../modules/cruise-control/proc-fixing-problems-with-kafkarebalance.adoc[leveloffset=+1] + +include::../../modules/cruise-control/proc-tracking-cluster-rebalance.adoc[leveloffset=+1] diff --git a/documentation/modules/cruise-control/proc-tracking-cluster-rebalance.adoc b/documentation/modules/cruise-control/proc-tracking-cluster-rebalance.adoc new file mode 100644 index 00000000000..10671a13abf --- /dev/null +++ b/documentation/modules/cruise-control/proc-tracking-cluster-rebalance.adoc @@ -0,0 +1,47 @@ +// Module included in the following assemblies: +// +// assembly-cruise-control-concepts.adoc + +[id='proc-tracking-cluster-rebalance-{context}'] + += Tracking rebalances + +Information surrounding the progress of an executing partition rebalance is useful for planning future cluster operations, such as worker node maintenance, scaling, or upgrading brokers. +Knowing details like the duration and data left to transfer for an ongoing partition rebalance can help users schedule maintenance windows effectively and assess the impact of continuing versus canceling a rebalance. + +Strimzi provides the following rebalance progress information fields in the `ConfigMap` listed in the `status.progress.rebalanceProgressConfigMap` of the `KafkaRebalance` resource. + +- `estimatedTimeToCompletionInMinutes`: The estimated time it will take in minutes until the partition rebalance is complete. + +- `completedByteMovementPercentage`: The percentage of the byte movement of the partition rebalance that is completed as a rounded down integer value in the range [0-100]. + +- `executorState.json`: The “non-verbose” JSON payload from the link:https://github.com/linkedin/cruise-control/wiki/REST-APIs#query-the-state-of-cruise-control[/kafkacruisecontrol/state?substates=executor] endpoint, providing details about the executor's current status, including partition movement progress, concurrency limits, and total data to move. + +This information is updated every reconciliation of the `KafkaRebalance` resource. + +.Prerequisites + +* The status of the `KafkaRebalance` custom resource is `Rebalancing` state. + +.Procedure + +- Accessing `estimatedTimeToCompletionInMinutes` field.: ++ +[source,shell] +---- +kubectl get configmaps -o json | jq '.["data"]["estimatedTimeToCompletionInMinutes"]' +---- + +- Accessing `completedByteMovementPercentage` field.: ++ +[source,shell] +---- +kubectl get configmaps -o json | jq '.["data"]["completedByteMovementPercentage"]' +---- + +- Accessing `executorState.json` field. ++ +[source,shell] +---- +kubectl get configmaps -o json | jq '.["data"]["executorState.json"] | fromjson | .' +----