mirror of
https://github.com/Psychotoxical/psysonic.git
synced 2026-07-22 07:15:47 +00:00
refactor(app_api): extract perf telemetry into own submodule
Lift PerformanceCpuSnapshot struct + the Linux /proc/stat parsers (parse_proc_stat_line / read_total_jiffies / collect_proc_stats) + the performance_cpu_snapshot Tauri command (~110 LOC) out of app_api/core.rs into app_api/perf.rs. Self-contained CPU-usage telemetry; nothing else in app_api references the helpers. This is the "telemetry" slice cucadmuh's plan called out for splitting core.rs's mixed runtime/platform/snapshot concerns. Other slices (cli-bridge, runtime-control, platform window/scrolling) can follow. app_api/core.rs: 235 → 122 LOC. lib.rs registration unchanged — performance_cpu_snapshot is re-exported through `pub(crate) use perf::*` in app_api/mod.rs.
This commit is contained in:
@@ -2,12 +2,14 @@ use super::*;
|
||||
|
||||
mod core;
|
||||
mod navidrome;
|
||||
mod perf;
|
||||
mod remote;
|
||||
mod integration;
|
||||
mod analysis;
|
||||
|
||||
pub(crate) use core::*;
|
||||
pub(crate) use navidrome::*;
|
||||
pub(crate) use perf::*;
|
||||
pub(crate) use remote::*;
|
||||
pub(crate) use integration::*;
|
||||
pub(crate) use analysis::*;
|
||||
|
||||
Reference in New Issue
Block a user