15 lines
296 B
Go
15 lines
296 B
Go
package agent
|
|
|
|
import (
|
|
"net/http"
|
|
)
|
|
|
|
func (s *HTTPServer) ClientStatsRequest(resp http.ResponseWriter, req *http.Request) (interface{}, error) {
|
|
if s.agent.client == nil {
|
|
return nil, clientNotRunning
|
|
}
|
|
|
|
clientStats := s.agent.client.StatsReporter()
|
|
return clientStats.HostStats(), nil
|
|
}
|