Skip to content

Commit

Permalink
enhance: print all index params
Browse files Browse the repository at this point in the history
Signed-off-by: zhenshan.cao <[email protected]>
  • Loading branch information
czs007 committed Jan 18, 2024
1 parent a991162 commit be8a107
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions states/etcd/show/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -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 {

Check failure on line 86 in states/etcd/show/index.go

View workflow job for this annotation

GitHub Actions / lint

File is not `goimports`-ed (goimports)
fmt.Printf("%s:%s", v.GetKey(), v.GetValue())
}
fmt.Println("==================================================================")
}

Expand All @@ -97,5 +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("==================================================================")
}

0 comments on commit be8a107

Please sign in to comment.