struct cleanup
This commit is contained in:
parent
d69a4104fc
commit
4c6c707dd0
@ -9,14 +9,14 @@ pub struct ProcessInfo {
|
|||||||
pub pid: u32,
|
pub pid: u32,
|
||||||
pub name: String,
|
pub name: String,
|
||||||
pub cpu_usage: f32,
|
pub cpu_usage: f32,
|
||||||
pub mem_bytes: u64
|
pub mem_bytes: u64,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Serialize, Clone)]
|
#[derive(Debug, Serialize, Clone)]
|
||||||
pub struct DiskInfo {
|
pub struct DiskInfo {
|
||||||
pub name: String,
|
pub name: String,
|
||||||
pub total: u64,
|
pub total: u64,
|
||||||
pub available: u64
|
pub available: u64,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Serialize, Clone)]
|
#[derive(Debug, Serialize, Clone)]
|
||||||
@ -24,7 +24,7 @@ pub struct NetworkInfo {
|
|||||||
pub name: String,
|
pub name: String,
|
||||||
// cumulative totals since the agent started (client should diff to get rates)
|
// cumulative totals since the agent started (client should diff to get rates)
|
||||||
pub received: u64,
|
pub received: u64,
|
||||||
pub transmitted: u64
|
pub transmitted: u64,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Serialize)]
|
#[derive(Serialize)]
|
||||||
@ -41,5 +41,5 @@ pub struct Metrics {
|
|||||||
pub disks: Vec<DiskInfo>,
|
pub disks: Vec<DiskInfo>,
|
||||||
pub networks: Vec<NetworkInfo>,
|
pub networks: Vec<NetworkInfo>,
|
||||||
pub top_processes: Vec<ProcessInfo>,
|
pub top_processes: Vec<ProcessInfo>,
|
||||||
pub gpus: Option<Vec<GpuMetrics>>
|
pub gpus: Option<Vec<GpuMetrics>>,
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user