Network Traffic Visualizer is a JavaFX desktop application for visualizing network topologies and live traffic flows. It connects to an NDT API endpoint, renders nodes and links, animates flow paths in real time, and supports playback of historical data files.
- OS: Windows, macOS, or Linux
- Java: JDK 21
- Build tool: Maven (wrapper included via
./mvnw) - Network: Reachable NDT API endpoint for Real-time mode
Network-Traffic-Visualizer/
├── src/
│ ├── main/
│ │ ├── java/org/example/demo2/
│ │ └── resources/org/example/demo2/
├── images/
├── pom.xml
├── mvnw
├── mvnw.cmd
├── network_traffic_visualizer.sh
├── node_positions.json
├── node_positions_playback.json
├── porttable.json
├── protocoltable.json
└── settings.json
From the project root:
./mvnw clean compile
./mvnw clean packagechmod +x ./network_traffic_visualizer.sh
./network_traffic_visualizer.shYou can also run directly with:
./mvnw javafx:runmvnw.cmd javafx:runThe app reads the API base URL from NDT_API_URL (default: http://localhost:8000).
export NDT_API_URL="http://your-server:8000"Endpoints used:
/ndt/get_graph_data/ndt/get_detected_flow_data/ndt/get_cpu_utilization/ndt/get_memory_utilization
Use the Playback panel in the UI to load:
- Flow data file (JSON or NDJSON)
- Topology data file (JSON or NDJSON)
Notes:
- Large JSON files are automatically converted to NDJSON in a
preprocessed/folder. - Index files (
.idx) are generated next to the selected data files for fast seeking. - NDJSON entries should include a timestamp field named
tortimestamp.
These files are read or written in the project root:
settings.json: saved UI settings (flow speed).node_positions.json: saved node layout for live mode.node_positions_playback.json: saved node layout for playback mode.porttable.json/protocoltable.json: lookup tables used in the Info dialog.
- API connection errors: verify
NDT_API_URLand server availability. - JavaFX errors: confirm JDK 21 is installed and Maven dependencies are downloaded.
mkdir -p ~/.local/share/applications
cat > ~/.local/share/applications/network-traffic-visualizer.desktop <<'EOF'
[Desktop Entry]
Type=Application
Name=Network Traffic Visualizer
Exec=/bin/bash -lc "cd /path/to/Network-Traffic-Visualizer && ./network_traffic_visualizer.sh"
Icon=/path/to/Network-Traffic-Visualizer/images/NDTwin.jpg
Terminal=false
Categories=Network;Development;
EOF
chmod +x ~/.local/share/applications/network-traffic-visualizer.desktopReplace /path/to/Network-Traffic-Visualizer with your actual project path.