mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-07-27 08:14:33 +08:00
bf40b0138c
- Add usage_daily_rollups table (schema v6) to aggregate proxy request logs into daily summaries, reducing query overhead for statistics - Add rollup_and_prune DAO that aggregates old detail logs (>N days) into rollup rows and deletes the originals - Update all usage stats queries to UNION detail logs with rollup data - Introduce incremental auto-vacuum for SQLite, with startup and periodic cleanup of old stream_check_logs and request log rollups - Split backup export/import into full vs sync variants: WebDAV sync now skips local-only table data (proxy_request_logs, stream_check_logs, provider_health, proxy_live_backup, usage_daily_rollups) while preserving them on import - Add enable_logging guard to skip request log writes when disabled - Apply cargo fmt formatting fixes across multiple modules
19 lines
424 B
Rust
19 lines
424 B
Rust
//! Data Access Object layer
|
|
//!
|
|
//! Database access operations for each domain
|
|
|
|
pub mod failover;
|
|
pub mod mcp;
|
|
pub mod prompts;
|
|
pub mod providers;
|
|
pub mod proxy;
|
|
pub mod settings;
|
|
pub mod skills;
|
|
pub mod stream_check;
|
|
pub mod universal_providers;
|
|
pub mod usage_rollup;
|
|
|
|
// 所有 DAO 方法都通过 Database impl 提供,无需单独导出
|
|
// 导出 FailoverQueueItem 供外部使用
|
|
pub use failover::FailoverQueueItem;
|