Cleanup: over-engineering pass

- merge /api/uptime + /api/version into /api/health and /api/stats
- collapse RTMP per-codec dispatch into a single CodecParser path
- dedupe STUN attribute walking (ufrag_pair / parse_xor_mapped_address)
- dedupe StreamCodec <-> str0m Codec mapping via StreamCodec::from_str0m
- dedupe bearer token extraction in WHIP handlers
- replace regex charset validation with stdlib checks
- flatten one-field wrappers (WebRtcProxyConfig, HttpServerConfig, ServerInfo)
- remove SessionCookie extractor (only fed debug logs)
- delete dead code: entity ActiveModel helpers, get_stream_session,
  WebrtcProxy::local_addr, _connected flag, commented-out blocks
- drop unused deps: futures, rand, regex, serde_json
This commit is contained in:
2026-08-21 11:39:02 +01:00
parent 0a039a97c4
commit 98dbb3d36d
11 changed files with 113 additions and 353 deletions
-4
View File
@@ -15,20 +15,17 @@ path = "src/main.rs"
async-broadcast = "0.7.2"
bytes = "1"
dashmap = "6.2.1"
rand = "0.10.1"
rml_rtmp = "0.8.0"
str0m = "0.20.0"
tokio = { version = "1", features = ["full"] }
axum = { version = "0.8", features = ["macros"] }
serde = { version = "1.0.228", features = ["serde_derive"] }
serde_json = "1.0.150"
sea-orm = { version = "1", features = [ "sqlx-sqlite", "runtime-tokio-rustls", "macros" ] }
entity = {path = "../entity"}
migration = {path = "../migration"}
argon2 = "0.5.3"
uuid = { version = "1.23.3", features = ["v4"] }
tower-http = { version = "0.6", features = ["cors"] }
futures = "0.3.32"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
symphonia = { version = "0.5", features = ["aac"] }
@@ -36,7 +33,6 @@ opus = "0.3.1"
rubato = "3.0.0"
chrono = "0.4.45"
time = "0.3"
regex = "1"
thiserror = "2.0.18"
sysinfo = "0.36"
axum-extra = { version = "0.12.6", features = ["cookie"] }