This is an automated email from the ASF dual-hosted git repository.

hubcio pushed a commit to branch feat/partition-routing
in repository https://gitbox.apache.org/repos/asf/iggy.git

commit 3b509db3fec5446e044ab20422adede1baf92301
Author: Hubert Gruszecki <[email protected]>
AuthorDate: Tue Oct 13 18:26:33 2026 +0200

    fix(cli): display replica IDs in cluster metadata
---
 core/cli/src/commands/binary_cluster/get_cluster_metadata.rs       | 5 ++++-
 core/integration/tests/cli/system/test_cluster_metadata_command.rs | 1 +
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/core/cli/src/commands/binary_cluster/get_cluster_metadata.rs 
b/core/cli/src/commands/binary_cluster/get_cluster_metadata.rs
index e1545f17e..fdb63b014 100644
--- a/core/cli/src/commands/binary_cluster/get_cluster_metadata.rs
+++ b/core/cli/src/commands/binary_cluster/get_cluster_metadata.rs
@@ -73,6 +73,7 @@ impl CliCommand for GetClusterMetadataCmd {
                 let mut table = Table::new();
 
                 table.set_header(vec![
+                    "Replica ID",
                     "Name",
                     "IP",
                     "TCP",
@@ -85,6 +86,7 @@ impl CliCommand for GetClusterMetadataCmd {
 
                 cluster_metadata.nodes.iter().for_each(|node| {
                     table.add_row(vec![
+                        node.replica_id.to_string(),
                         node.name.to_string(),
                         node.ip.to_string(),
                         node.endpoints.tcp.to_string(),
@@ -101,7 +103,8 @@ impl CliCommand for GetClusterMetadataCmd {
             GetClusterMetadataOutput::List => {
                 cluster_metadata.nodes.iter().for_each(|node| {
                     event!(target: PRINT_TARGET, Level::INFO,
-                        "{}|{}|{}|{}|{}|{}|{}|{}",
+                        "{}|{}|{}|{}|{}|{}|{}|{}|{}",
+                        node.replica_id,
                         node.name,
                         node.ip,
                         node.endpoints.tcp,
diff --git a/core/integration/tests/cli/system/test_cluster_metadata_command.rs 
b/core/integration/tests/cli/system/test_cluster_metadata_command.rs
index 236bf00ca..85dfb18ad 100644
--- a/core/integration/tests/cli/system/test_cluster_metadata_command.rs
+++ b/core/integration/tests/cli/system/test_cluster_metadata_command.rs
@@ -63,6 +63,7 @@ impl IggyCmdTestCase for TestClusterMetadataCmd {
                         "Executing get cluster metadata in table mode\n",
                     ))
                     .stdout(contains("Cluster name:"))
+                    .stdout(contains("Replica ID"))
                     .stdout(contains("Name"))
                     .stdout(contains("IP"))
                     .stdout(contains("TCP"))

Reply via email to