Replace two-node-udp with Docker network test harness, fix dead code warnings

Replace examples/two-node-udp/ (netns-based) with examples/docker-network/
(Docker compose, 5 nodes, mesh + chain topologies). The new harness uses
auto-detecting build script and includes SVG topology diagrams.

Remove unused get_session_mut, remote_addr(), remote_pubkey() methods.
Gate test-only accessors with #[cfg(test)]. Zero warnings in release build.
This commit is contained in:
Johnathan Corgan
2026-02-14 18:38:26 +00:00
parent 801a5ab222
commit 5236fd02bf
23 changed files with 983 additions and 395 deletions
+2 -5
View File
@@ -806,16 +806,13 @@ impl Node {
// === End-to-End Sessions ===
/// Get a session by remote NodeAddr.
#[cfg(test)]
pub(crate) fn get_session(&self, remote: &NodeAddr) -> Option<&SessionEntry> {
self.sessions.get(remote)
}
/// Get a mutable session by remote NodeAddr.
pub(crate) fn get_session_mut(&mut self, remote: &NodeAddr) -> Option<&mut SessionEntry> {
self.sessions.get_mut(remote)
}
/// Remove a session.
#[cfg(test)]
pub(crate) fn remove_session(&mut self, remote: &NodeAddr) -> Option<SessionEntry> {
self.sessions.remove(remote)
}