Update server.rs
Test, build and publish / All tests and Linux binary (push) Failing after 17s
Test, build and publish / Container smoke test and Gitea publish (push) Skipped

This commit is contained in:
wt committed 2026-10-21 17:54:18 +07:00
1 parent 5b8ee4f4ad
commit c71aca637c
1 file changed
+13
+13
View File
@@ -233,6 +233,19 @@ impl ConnectionLog {
.and_then(|e| e.downcast_ref::<std::io::Error>())
.map(|e| format!("{:?}", e.kind()))
.unwrap_or_else(|| "none".into());
// TEMP-DIAG: sanitized, non-payload invariant label to locate a session
// fault (e.g. "stream management store failed", "retired stream
// transport", "missing stanza name"). Values come from the error chain
// only and never contain payload, tokens or passwords.
if let Err(e) = result {
let label = e
.chain()
.map(|x| x.to_string())
.find(|s| s.chars().all(|c| c.is_ascii() && !c.is_control()))
.unwrap_or_default();
let label: String = label.chars().take(160).collect();
self.event(Level::Debug, "session-error-label", &[("err", &label)]);
}
self.event(
if result.is_err() && !matches!(reason, "peer-disconnected" | "stream-complete") {
Level::Warn