Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions metrics/group_processes.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ func (p *ProcessesMetricGroup) GetMetrics(status *models.FullStatus) {
tags := p.getTags(processName, &process)
metrics["degraded"] = process.Degraded
metrics["excluded"] = process.Excluded
metrics["run_loop_busy"] = process.RunLoopBusy
if process.Cpu != nil {
metrics["cpu_cores"] = process.Cpu.UsageCores
}
Expand Down
1 change: 1 addition & 0 deletions models/process.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ type Process struct {
Messages []ProcessMessage `json:"messages"`
Network *ProcessNetwork `json:"network"`
Roles []ProcessRole `json:"roles"`
RunLoopBusy float64 `json:"run_loop_busy"`
}

type ProcessCpu struct {
Expand Down
1 change: 1 addition & 0 deletions models/process_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ func TestProcessSingleBasic(t *testing.T) {
assert.False(t, process.Excluded)
assert.Equal(t, process.FaultDomain, "2f768c26fc0f01ce8af5402f7779b62c")
assert.Equal(t, process.MachineId, "2f768c26fc0f01ce8af5402f7779b62c")
assert.Greater(t, process.RunLoopBusy, 0.0)
}

func TestProcessCpuSingleBasic(t *testing.T) {
Expand Down