Skip to content

Commit e5921d7

Browse files
committed
[coconut] Update GetFrameworkInfo call to show core instance and version
1 parent 6a21edb commit e5921d7

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

coconut/control/control.go

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ import (
3939
"github.com/AliceO2Group/Control/coconut"
4040
"github.com/AliceO2Group/Control/coconut/protos"
4141
"github.com/AliceO2Group/Control/common/logger"
42-
"github.com/AliceO2Group/Control/common/product"
4342
"github.com/briandowns/spinner"
4443
"github.com/olekukonko/tablewriter"
4544
"github.com/sirupsen/logrus"
@@ -106,11 +105,13 @@ func GetInfo(cxt context.Context, rpc *coconut.RpcClient, cmd *cobra.Command, ar
106105
return
107106
}
108107

109-
fmt.Fprintf(o, "%s core running on %s\n", product.PRETTY_SHORTNAME, viper.GetString("endpoint"))
110-
fmt.Fprintf(o, "framework id: %s\n", response.GetFrameworkId())
111-
fmt.Fprintf(o, "environments count: %d\n", response.GetEnvironmentsCount())
112-
fmt.Fprintf(o, "active tasks count: %d\n", response.GetTasksCount())
113-
fmt.Fprintf(o, "global state: %s\n", response.GetState())
108+
_, _ = fmt.Fprintf(o, "instance name: %s\n", response.GetInstanceName())
109+
_, _ = fmt.Fprintf(o, "endpoint: %s\n", viper.GetString("endpoint"))
110+
_, _ = fmt.Fprintf(o, "core version: %s %s build %s\n", response.GetVersion().GetProductName(), response.GetVersion().GetVersionStr(), response.GetVersion().GetBuild())
111+
_, _ = fmt.Fprintf(o, "framework id: %s\n", response.GetFrameworkId())
112+
_, _ = fmt.Fprintf(o, "environments count: %d\n", response.GetEnvironmentsCount())
113+
_, _ = fmt.Fprintf(o, "active tasks count: %d\n", response.GetTasksCount())
114+
_, _ = fmt.Fprintf(o, "global state: %s\n", response.GetState())
114115

115116
return nil
116117
}

0 commit comments

Comments
 (0)