73 lines
1.6 KiB
TOML
73 lines
1.6 KiB
TOML
[package]
|
||
name = "iam-service"
|
||
version = "0.1.0"
|
||
edition = "2024"
|
||
|
||
[dependencies]
|
||
common-telemetry = { version = "0.1.5", registry = "kellnr", default-features = false, features = [
|
||
"response",
|
||
"telemetry",
|
||
"with-anyhow",
|
||
"with-sqlx",
|
||
] } # 内部公共库(统一错误/响应/日志/Telemetry)
|
||
|
||
# Web 框架与 HTTP 基础
|
||
axum = "0.8.8"
|
||
http = "1.4.0"
|
||
|
||
# 异步运行时与通用异步工具
|
||
async-trait = "0.1.89"
|
||
tokio = { version = "1", features = ["full"] }
|
||
|
||
# 序列化
|
||
serde = { version = "1", features = ["derive"] }
|
||
serde_json = "1"
|
||
|
||
# 数据库 (PostgreSQL)
|
||
sqlx = { version = "0.8", features = [
|
||
"chrono",
|
||
"json",
|
||
"postgres",
|
||
"runtime-tokio-native-tls",
|
||
"uuid",
|
||
] }
|
||
|
||
# 配置管理
|
||
config = "0.15.19" # 方便读取配置
|
||
dotenvy = "0.15" # 加载 .env
|
||
|
||
# 错误处理
|
||
anyhow = "1"
|
||
thiserror = "2.0.18"
|
||
|
||
# 可观测性(日志与 tracing)
|
||
tracing = "0.1"
|
||
tracing-subscriber = "0.3"
|
||
|
||
# 安全与加密(密码、JWT、密钥/编码)
|
||
argon2 = "0.5"
|
||
base64 = "0.22.1"
|
||
hex = "0.4.3"
|
||
jsonwebtoken = { version = "10.3.0", features = ["aws_lc_rs"] }
|
||
rand = "0.9.2"
|
||
rsa = "0.9.10"
|
||
uuid = { version = "1", features = ["v4", "serde"] }
|
||
hmac = "0.12.1"
|
||
sha2 = "0.10.9"
|
||
|
||
# API 文档 (OpenAPI/Scalar)
|
||
utoipa = { version = "5", features = ["axum_extras", "uuid", "chrono"] }
|
||
utoipa-scalar = { version = "0.3.0", features = ["axum"] } # Scalar 集成
|
||
|
||
# 中间件组件(限流)
|
||
governor = "0.10.4"
|
||
ipnet = "2.11.0"
|
||
tower_governor = { version = "0.8.0", features = ["axum"] }
|
||
|
||
# 时间处理
|
||
chrono = "0.4.43"
|
||
|
||
[dev-dependencies]
|
||
# 测试工具
|
||
tower = "0.5"
|