refactor: 统一项目名称从OpenFang到ZCLAW
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled

重构所有代码和文档中的项目名称,将OpenFang统一更新为ZCLAW。包括:
- 配置文件中的项目名称
- 代码注释和文档引用
- 环境变量和路径
- 类型定义和接口名称
- 测试用例和模拟数据

同时优化部分代码结构,移除未使用的模块,并更新相关依赖项。
This commit is contained in:
iven
2026-03-27 07:36:03 +08:00
parent 4b08804aa9
commit 0d4fa96b82
226 changed files with 7288 additions and 5788 deletions

View File

@@ -9,8 +9,6 @@
//!
//! NOTE: Some methods are reserved for future proactive features.
#![allow(dead_code)] // Methods reserved for future proactive features
use chrono::{Local, Timelike};
use serde::{Deserialize, Serialize};
use std::collections::HashMap;
@@ -94,6 +92,7 @@ pub enum HeartbeatStatus {
}
/// Type alias for heartbeat check function
#[allow(dead_code)] // Reserved for future proactive check registration
pub type HeartbeatCheckFn = Box<dyn Fn(String) -> std::pin::Pin<Box<dyn std::future::Future<Output = Option<HeartbeatAlert>> + Send>> + Send + Sync>;
// === Default Config ===
@@ -187,6 +186,7 @@ impl HeartbeatEngine {
}
/// Check if the engine is running
#[allow(dead_code)] // Reserved for UI status display
pub async fn is_running(&self) -> bool {
*self.running.lock().await
}
@@ -197,6 +197,7 @@ impl HeartbeatEngine {
}
/// Subscribe to alerts
#[allow(dead_code)] // Reserved for future UI notification integration
pub fn subscribe(&self) -> broadcast::Receiver<HeartbeatAlert> {
self.alert_sender.subscribe()
}
@@ -355,7 +356,9 @@ static LAST_INTERACTION: OnceLock<RwLock<StdHashMap<String, String>>> = OnceLock
pub struct MemoryStatsCache {
pub task_count: usize,
pub total_entries: usize,
#[allow(dead_code)] // Reserved for UI display
pub storage_size_bytes: usize,
#[allow(dead_code)] // Reserved for UI display
pub last_updated: Option<String>,
}