59 lines
1.7 KiB
TOML
59 lines
1.7 KiB
TOML
[package]
|
||
name = "mcp-common"
|
||
version = "0.1.28"
|
||
edition = "2024"
|
||
authors = ["nuwax-ai"]
|
||
description = "Common types and utilities shared across MCP proxy components"
|
||
license = "MIT OR Apache-2.0"
|
||
repository = "https://github.com/nuwax-ai/mcp-proxy"
|
||
keywords = ["mcp", "proxy", "protocol"]
|
||
categories = ["web-programming", "network-programming"]
|
||
|
||
[dependencies]
|
||
# 基础依赖
|
||
serde = { workspace = true }
|
||
serde_json = { workspace = true }
|
||
|
||
# 日志
|
||
tracing = { workspace = true }
|
||
|
||
# 异步
|
||
async-trait = { workspace = true }
|
||
tokio = { workspace = true }
|
||
|
||
# 并发
|
||
arc-swap = { workspace = true }
|
||
dashmap = { workspace = true }
|
||
|
||
# 错误处理
|
||
anyhow = { workspace = true }
|
||
|
||
# 国际化支持
|
||
rust-i18n = { workspace = true }
|
||
|
||
# OpenTelemetry 核心(条件依赖)
|
||
opentelemetry = { workspace = true, optional = true }
|
||
opentelemetry_sdk = { workspace = true, optional = true }
|
||
tracing-opentelemetry = { workspace = true, optional = true }
|
||
tracing-subscriber = { workspace = true, optional = true }
|
||
|
||
# OTLP exporter(条件依赖)
|
||
opentelemetry-otlp = { workspace = true, optional = true }
|
||
tonic = { workspace = true, optional = true }
|
||
|
||
# 进程组管理(跨平台子进程清理)
|
||
# 版本需要与 mcp-streamable-proxy 保持一致
|
||
process-wrap = { version = "9.0.3", features = ["tokio1", "process-group", "job-object"] }
|
||
# 查找可执行文件
|
||
which = { workspace = true }
|
||
|
||
[target.'cfg(windows)'.dependencies]
|
||
windows = { version = "0.62", features = ["Win32_System_Threading"] }
|
||
|
||
[features]
|
||
default = []
|
||
# 基础 OpenTelemetry 支持
|
||
telemetry = ["opentelemetry", "opentelemetry_sdk", "tracing-opentelemetry", "tracing-subscriber"]
|
||
# OTLP exporter(需要 telemetry)
|
||
otlp = ["telemetry", "opentelemetry-otlp", "tonic"]
|