Files
sol-trade-sdk/Cargo.toml
T
0xfnzeroandCursor e8ec9103ab release: sol-trade-sdk 4.0.4
fix(swqos): extend parallel-submit wait/grace windows for late HTTP responses

- Scale primary submit timeout with configured channel count (clamped 3–5s)
- After primary expiry, optionally poll longer so slow providers still land before drain
- Short settle sleeps to reduce counter vs TaskResult races and dropped signatures when
  wait_transaction_confirmed is false

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-03 03:01:20 +08:00

151 lines
4.4 KiB
TOML
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
[package]
name = "sol-trade-sdk"
version = "4.0.4"
edition = "2021"
authors = [
"William <byteblock6@gmail.com>",
"sgxiang <sgxiang@gmail.com>",
"wei <1415121722@qq.com>",
]
repository = "https://github.com/0xfnzero/sol-trade-sdk"
description = "Rust SDK to interact with the dex trade Solana program."
license = "MIT"
keywords = ["solana", "memecoins", "pumpfun", "pumpswap", "raydium"]
readme = "README.md"
[workspace]
members = [
"examples/trading_client",
"examples/shared_infrastructure",
"examples/middleware_system",
"examples/pumpswap_trading",
"examples/pumpfun_copy_trading",
"examples/pumpfun_sniper_trading",
"examples/bonk_sniper_trading",
"examples/bonk_copy_trading",
"examples/raydium_cpmm_trading",
"examples/raydium_amm_v4_trading",
"examples/address_lookup",
"examples/nonce_cache",
"examples/pumpswap_direct_trading",
"examples/wsol_wrapper",
"examples/seed_trading",
"examples/cli_trading",
"examples/gas_fee_strategy",
"examples/meteora_damm_v2_direct_trading",
]
[lib]
crate-type = ["cdylib", "rlib"]
[features]
default = []
perf-trace = [] # 性能追踪特性,生产环境应禁用以获得最佳性能
[dependencies]
solana-sdk = "3.0.0"
solana-client = "3.1.12"
solana-program = "3.0.0"
solana-rpc-client = "3.1.12"
solana-rpc-client-api = "3.1.12"
solana-transaction-status = "3.1.12"
solana-account-decoder = "3.1.12"
solana-hash = "3.0.0"
solana-entry = "3.0.0"
solana-rpc-client-nonce-utils = "3.1.12"
solana-perf = "3.1.12"
solana-metrics = "3.1.12"
solana-tls-utils = "3.1.12"
solana-nonce = "3.2.0"
solana-address-lookup-table-interface = "3.0.0"
solana-message = "3.1.0"
solana-compute-budget-interface = "3.0.0"
solana-commitment-config = { version = "3.1.1", features = ["serde"] }
solana-transaction-status-client-types = "3.1.12"
solana-system-interface = { version = "3.0.0", features = ["bincode"] }
borsh = { version = "1.5.3", features = ["derive"] }
isahc = "1.7.2"
serde = { version = "1.0.215", features = ["derive"] }
serde_json = "1.0.134"
futures = "0.3.31"
futures-util = "0.3.31"
base64 = "0.22.1"
bs58 = "0.5.1"
rand = "0.9.0"
bincode = "1.3.3"
anyhow = "1.0.90"
reqwest = { version = "0.12.12", features = ["json", "multipart"] }
tokio = { version = "1.42.0" , features = ["full", "rt-multi-thread"]}
tonic = { version = "0.12", features = ["transport"] }
rustls = { version = "0.23.23", features = ["ring"] }
rustls-native-certs = "0.8.1"
tokio-rustls = "0.26.1"
core_affinity = "0.8"
chrono = "0.4.39"
regex = "1"
tracing = "0.1.41"
thiserror = "2.0.11"
async-trait = "0.1.86"
once_cell = "1.20.3"
prost = "0.13"
prost-types = "0.13"
num_enum = "0.7.3"
num-derive = "0.4.2"
num-traits = "0.2.19"
hex = "0.4.3"
bytemuck = { version = "1.4.0" }
arrayref = "0.3.6"
borsh-derive = "1.5.5"
indicatif = "0.18.0"
fnv = "1.0.7"
dashmap = "6.1.0"
clru = "0.6"
smallvec = "1.15.1"
parking_lot = "0.12"
arc-swap = "1.7"
sha2 = "0.10"
tonic-prost = "0.14.2"
# 须含 runtime-tokio,否则 quinn::Endpoint::client 报 no async runtime foundQUICSpeedlanding/Soyas)无法初始化
quinn = { version = "0.11", default-features = false, features = ["rustls", "runtime-tokio"] }
rcgen = "0.13"
uuid = "1.11"
# Performance optimization dependencies
crossbeam-queue = "0.3"
crossbeam-utils = "0.8"
memmap2 = "0.9"
num_cpus = "1.16"
libc = "0.2"
# 🚀 编译器优化配置 - 平衡性能与编译速度
[profile.release]
opt-level = 3 # 最高优化级别(不影响编译速度)
lto = "thin" # 瘦LTO - 平衡性能与编译速度(比fat快5-10倍)
codegen-units = 16 # 16个代码生成单元 - 并行编译(比1快10倍)
panic = "abort" # 恐慌即中止
overflow-checks = false # 禁用溢出检查
debug = false # 禁用调试信息
debug-assertions = false # 禁用调试断言
rpath = false
strip = true # 去除符号表
incremental = true # 增量编译 - 大幅加速重新编译
[profile.dev]
opt-level = 1 # 开发时适度优化
overflow-checks = true # 开发时启用溢出检查
# 🚀 构建依赖
# 注意:proto 代码已预生成在 src/swqos/pb/serverpb.rs
# 开发者如需重新生成代码,请运行 gen_proto 目录下的工具
# 🚀 性能关键依赖的特殊优化
[profile.release.package.solana-sdk]
opt-level = 3
[profile.release.package.bincode]
opt-level = 3