pub async fn update_unit_stats( config: Arc<Config>, locked_machine_stats: Arc<RwLock<MachineStats>>, socket_path: String, ) -> Result<()>
Async wrapper that can update unit stats when passed a locked struct.