How alptekinsunnetci/netplotter works
rp is a real-time terminal network-path monitor. The user supplies one or more targets and probing options; the CLI resolves targets, runs periodic traceroutes, accumulates per-hop metrics, and presents live panels, with optional exports and comparison to an earlier JSON export. The README documents several capabilities whose implementation details are not fully sampled; the graph includes their supported modules and omits uncertain wiring. Main orchestration and core probe/metrics behavior are sampled; some subsystem links rely on README documentation.
Main entry points: main.go Monitor runtime · factory.go Probe factory · storage.go Export backends · baseline.go Diff baseline
Components 25
CLI orchestration
- Monitor runtime
cmd/rp/main.go - CLI configuration
internal/config/config.go - Diff baseline
internal/diff/baseline.go
Path discovery
- Traceroute runner
internal/traceroute/traceroute.go - Hop model
internal/traceroute/hop.go - Probe factory
internal/probe/factory.go - ICMP probers
internal/probe/icmp.go - ICMPv6 probers
internal/probe/icmp6.go - Windows ICMP
internal/probe/icmp_windows.go - TCP prober
internal/probe/tcp.go
Metrics enrichment
- Session metrics
internal/metrics/session.go - Per-hop statistics
internal/metrics/hopmetrics.go - Sample buffer
internal/metrics/buffer.go - Reverse DNS cache
internal/dns/resolver.go
Monitoring outputs
- Terminal renderer
internal/renderer/terminal.go - Export backends
internal/storage/storage.go - JSON export
internal/storage/json.go - CSV export
internal/storage/csv.go - Text export
internal/storage/txt.go
Other components
- Operator
- Target network
- DNS service
- Terminal
- Export files
- Prior JSON export
Connections 30
- Operator → Monitor runtime: starts monitor
- Monitor runtime → CLI configuration: parses options
- Monitor runtime → Diff baseline: loads comparison
- Diff baseline → Prior JSON export: reads JSON
- Monitor runtime → Probe factory: creates prober
- Monitor runtime → Traceroute runner: runs routes
- Traceroute runner → Probe factory: probes TTLs
- Probe factory → ICMP probers: selects ICMP
- Probe factory → ICMPv6 probers: selects ICMPv6
- Probe factory → Windows ICMP: selects Windows
- Probe factory → TCP prober: selects TCP
- ICMP probers → Target network: sends probes
- ICMPv6 probers → Target network: sends probes
- Windows ICMP → Target network: sends probes
- TCP prober → Target network: connects to target
- Monitor runtime → Session metrics: records results
- Session metrics → Per-hop statistics: updates hop stats
- Per-hop statistics → Sample buffer: stores samples
- Monitor runtime → Reverse DNS cache: resolves hop names
- Reverse DNS cache → DNS service: looks up names
- Monitor runtime → Terminal renderer: renders snapshots
- Terminal renderer → Terminal: draws panels
- Terminal → Monitor runtime: sends commands
- Monitor runtime → Export backends: exports snapshots
- Export backends → JSON export: writes JSON
- Export backends → CSV export: writes CSV
- Export backends → Text export: writes text
- JSON export → Export files: writes export
- CSV export → Export files: writes export
- Text export → Export files: writes export