snapper + client/status: snapshotting reports

This commit is contained in:
Christian Schwarz
2019-09-19 00:13:55 +02:00
parent 729c83ee72
commit b5ff1a9926
8 changed files with 277 additions and 23 deletions
+3 -1
View File
@@ -66,7 +66,8 @@ func (j *SnapJob) RegisterMetrics(registerer prometheus.Registerer) {
}
type SnapJobStatus struct {
Pruning *pruner.Report
Pruning *pruner.Report
Snapshotting *snapper.Report // may be nil
}
func (j *SnapJob) Status() *Status {
@@ -75,6 +76,7 @@ func (j *SnapJob) Status() *Status {
if j.pruner != nil {
s.Pruning = j.pruner.Report()
}
s.Snapshotting = j.snapper.Report()
return &Status{Type: t, JobSpecific: s}
}