From 326786e4ff5a9ff47dd4902dd981ac9d2d6bcad9 Mon Sep 17 00:00:00 2001 From: MBovtriukProvectus <72087783+MBovtriukProvectus@users.noreply.github.com> Date: Wed, 21 Jul 2021 15:55:30 +0300 Subject: [PATCH] Display replication factor field in topics list #608 (#697) --- kafka-ui-react-app/src/components/Topics/List/List.tsx | 1 + kafka-ui-react-app/src/components/Topics/List/ListItem.tsx | 3 ++- .../Topics/List/__tests__/__snapshots__/List.spec.tsx.snap | 3 +++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/kafka-ui-react-app/src/components/Topics/List/List.tsx b/kafka-ui-react-app/src/components/Topics/List/List.tsx index 8bc231a98d..34b7bc8a95 100644 --- a/kafka-ui-react-app/src/components/Topics/List/List.tsx +++ b/kafka-ui-react-app/src/components/Topics/List/List.tsx @@ -135,6 +135,7 @@ const List: React.FC = ({ orderBy={orderBy} setOrderBy={setTopicsOrderBy} /> + Replication Factor Number of messages Size Type diff --git a/kafka-ui-react-app/src/components/Topics/List/ListItem.tsx b/kafka-ui-react-app/src/components/Topics/List/ListItem.tsx index 6a086771a9..ea2e99953f 100644 --- a/kafka-ui-react-app/src/components/Topics/List/ListItem.tsx +++ b/kafka-ui-react-app/src/components/Topics/List/ListItem.tsx @@ -20,7 +20,7 @@ export interface ListItemProps { } const ListItem: React.FC = ({ - topic: { name, internal, partitions, segmentSize }, + topic: { name, internal, partitions, segmentSize, replicationFactor }, deleteTopic, clusterName, clearTopicMessages, @@ -75,6 +75,7 @@ const ListItem: React.FC = ({ {partitions?.length} {outOfSyncReplicas} + {replicationFactor} {numberOfMessages} diff --git a/kafka-ui-react-app/src/components/Topics/List/__tests__/__snapshots__/List.spec.tsx.snap b/kafka-ui-react-app/src/components/Topics/List/__tests__/__snapshots__/List.spec.tsx.snap index 17a86b1f2f..b3012f8138 100644 --- a/kafka-ui-react-app/src/components/Topics/List/__tests__/__snapshots__/List.spec.tsx.snap +++ b/kafka-ui-react-app/src/components/Topics/List/__tests__/__snapshots__/List.spec.tsx.snap @@ -205,6 +205,9 @@ exports[`List when it does not have readonly flag matches the snapshot 1`] = ` + + Replication Factor + Number of messages