Port relay service from Python to Rust + Rouille
- PostgreSQL with chrono datetime support - JWT authentication (jsonwebtoken crate) - bcrypt API key hashing - In-memory rate limiter (10 req/min for chat) - HTTP proxy to reason/recall services - ~3.8MB binary vs ~50MB Python Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
8ad87ddaaa
commit
fd3802d749
3 changed files with 2927 additions and 0 deletions
21
Cargo.toml
Normal file
21
Cargo.toml
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
[package]
|
||||
name = "relay"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
rouille = "3.6"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
chrono = { version = "0.4", features = ["serde"] }
|
||||
postgres = { version = "0.19", features = ["with-chrono-0_4"] }
|
||||
jsonwebtoken = "9.2"
|
||||
bcrypt = "0.15"
|
||||
ureq = { version = "2.9", features = ["json"] }
|
||||
uuid = { version = "1.0", features = ["v4"] }
|
||||
rand = "0.8"
|
||||
hex = "0.4"
|
||||
|
||||
[profile.release]
|
||||
strip = true
|
||||
lto = true
|
||||
Loading…
Add table
Add a link
Reference in a new issue