Files
mock-server/Cargo.toml
CNWei 7d517a89c9 merge: 合并热重载功能分支
合并 feature-ms-v0.0.1-SNAPSHOOT-20260319 的热重载实现:
- 使用 notify-debouncer-mini 监听 mocks 目录变化
- AppState 使用 RwLock<MockRouter> 支持并发读写
- 200ms 防抖避免编辑器保存时的多次触发

保留当前分支的功能:
- 文件上传功能 (upload.rs)
- 请求体 body 匹配支持
- 完整的测试覆盖 (43个测试)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-19 22:20:20 +08:00

42 lines
973 B
TOML

[package]
name = "mock_server"
version = "0.1.0"
edition = "2024"
[dependencies]
# 核心 Web 框架
axum = "0.8.8"
axum-extra = { version = "0.10", features = ["multipart"] }
# 异步运行时
tokio={version = "1.48.0",features = ["full"]}
# 异步文件操作与流处理工具
tokio-util = {version = "0.7.17",features = ["io"]}
futures-util = "0.3.31"
# 序列化与 YAML 解析
serde = {version = "1.0.228",features = ["derive"]}
serde_yaml = "0.9.34+deprecated"
serde_json = "1.0.147"
# 物理目录递归扫描工具
walkdir = "2.5.0"
# UUID 生成(用于唯一文件名)
uuid = { version = "1.0", features = ["v4", "serde"] }
# 日期时间处理
chrono = "0.4"
tracing="0.1.44"
tracing-subscriber = "0.3.22"
# 性能优化:快速哈希(可选,用于路由匹配)
#dashmap = "7.0.0-rc2"
# 热加载支持(扩展功能)
notify = "8.2.0"
notify-debouncer-mini = "0.6.0"
# 路径处理
#pathdiff = "0.2.3"
[dev-dependencies]
tempfile = "3.24.0"