From 8d94391f6be78635c1fe8dda52f7b3e1337805cc Mon Sep 17 00:00:00 2001 From: "zhenshan.cao" Date: Thu, 18 Jan 2024 16:55:44 +0800 Subject: [PATCH] enhance: print all index params Signed-off-by: zhenshan.cao --- states/etcd/show/index.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/states/etcd/show/index.go b/states/etcd/show/index.go index b142126..ff343dc 100644 --- a/states/etcd/show/index.go +++ b/states/etcd/show/index.go @@ -83,6 +83,9 @@ func printIndex(index IndexInfoV1) { common.GetKVPair(indexParams, "metric_type"), ) fmt.Printf("Index Params: %s\n", common.GetKVPair(index.info.GetIndexParams(), "params")) + for _ , v := range indexParams { + fmt.Printf("%s:%s", v.GetKey(), v.GetValue()) + } fmt.Println("==================================================================") } @@ -97,4 +100,8 @@ func printIndexV2(index indexpbv2.FieldIndex) { common.GetKVPair(indexParams, "metric_type"), ) fmt.Printf("Index Params: %s\n", common.GetKVPair(index.GetIndexInfo().GetUserIndexParams(), "params")) + for _ , v := range indexParams { + fmt.Printf("%s:%s", v.GetKey(), v.GetValue()) + } + fmt.Println("==================================================================") }