MCPcopy
hub / github.com/NVIDIA/aistore / getRandTargetConfig

Function getRandTargetConfig

cmd/cli/commands/utils.go:254–268  ·  view source on GitHub ↗

Get config from random target.

()

Source from the content-addressed store, hash-verified

252
253// Get config from random target.
254func getRandTargetConfig() (*cmn.Config, error) {
255 smap, err := api.GetClusterMap(defaultAPIParams)
256 if err != nil {
257 return nil, err
258 }
259 si, err := smap.GetRandTarget()
260 if err != nil {
261 return nil, err
262 }
263 cfg, err := api.GetDaemonConfig(defaultAPIParams, si)
264 if err != nil {
265 return nil, err
266 }
267 return cfg, err
268}
269
270func isConfigProp(s string) bool {
271 props := configPropList()

Callers 1

startDownloadHandlerFunction · 0.85

Calls 3

GetClusterMapFunction · 0.92
GetDaemonConfigFunction · 0.92
GetRandTargetMethod · 0.80

Tested by

no test coverage detected