nomad: expose RuntimeStats
This commit is contained in:
parent
0383bf3c14
commit
40def1a187
|
@ -145,7 +145,7 @@ func (c *Client) Stats() map[string]map[string]string {
|
|||
"server": "false",
|
||||
"known_servers": toString(uint64(len(c.config.ServerAddress))),
|
||||
},
|
||||
"runtime": runtimeStats(),
|
||||
"runtime": RuntimeStats(),
|
||||
}
|
||||
return stats
|
||||
}
|
||||
|
|
|
@ -640,7 +640,7 @@ func (s *Server) Stats() map[string]map[string]string {
|
|||
},
|
||||
"raft": s.raft.Stats(),
|
||||
"serf": s.serf.Stats(),
|
||||
"runtime": runtimeStats(),
|
||||
"runtime": RuntimeStats(),
|
||||
}
|
||||
return stats
|
||||
}
|
||||
|
|
|
@ -22,8 +22,8 @@ func ensurePath(path string, dir bool) error {
|
|||
return os.MkdirAll(path, 0755)
|
||||
}
|
||||
|
||||
// runtimeStats is used to return various runtime information
|
||||
func runtimeStats() map[string]string {
|
||||
// RuntimeStats is used to return various runtime information
|
||||
func RuntimeStats() map[string]string {
|
||||
return map[string]string{
|
||||
"os": runtime.GOOS,
|
||||
"arch": runtime.GOARCH,
|
||||
|
|
Loading…
Reference in a new issue