diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2017-11-30 17:14:18 +0100 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2017-12-01 13:58:11 +0100 |
| commit | 2fa91450df792689c42bd52f98ffdacee99ace91 (patch) | |
| tree | 6bac47c9c556725b596af31c0212d57fc6157575 /dashboard/dashapi | |
| parent | 5683420f11c9eb812a57f2c5786b38015a652fa0 (diff) | |
dashboard/app: add manager monitoring
Make it possible to monitor health and operation
of all managers from dashboard.
1. Notify dashboard about internal syz-ci errors
(currently we don't know when/if they happen).
2. Send statistics from managers to dashboard.
Diffstat (limited to 'dashboard/dashapi')
| -rw-r--r-- | dashboard/dashapi/dashapi.go | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/dashboard/dashapi/dashapi.go b/dashboard/dashapi/dashapi.go index 8ebea29ac..4ba797f32 100644 --- a/dashboard/dashapi/dashapi.go +++ b/dashboard/dashapi/dashapi.go @@ -16,6 +16,7 @@ import ( "net/url" "reflect" "strings" + "time" ) type Dashboard struct { @@ -249,6 +250,23 @@ type PollResponse struct { Reports []*BugReport } +type ManagerStatsReq struct { + Name string + // Current level: + UpTime time.Duration + Corpus uint64 + Cover uint64 + + // Delta since last sync: + FuzzingTime time.Duration + Crashes uint64 + Execs uint64 +} + +func (dash *Dashboard) UploadManagerStats(req *ManagerStatsReq) error { + return dash.query("manager_stats", req, nil) +} + type ( BugStatus int ReproLevel int |
