System-Wide vs Per-Node
The two simulator integration topologies NSB supports, with their diagrams, constraints, and which real-world simulators use each.
System-Wide Patternโ
A single simulator client handles all message routing. When a payload is fetched, it can come from any source node.
Constraint: Only one NSBSimClient may connect to the daemon at a time in this mode.
Best for: Top-down simulators like ns-3, custom script-driven simulations โ where a single simulation script manages the entire network.
Per-Node Patternโ
Each simulated node has its own simulator client. The client identifier for NSBSimClient must match the corresponding NSBAppClient identifier.
Identifier matching rule: NSBSimClient("node0") only fetches messages sent from AppClient("node0"), and posts make the payload available to AppClient at the destination โ so the simulator client's identifier string must exactly match its corresponding application client's identifier string.
Best for: Bottom-up simulators like OMNeT++, node-module-based simulators โ where each simulated host module directly handles its own traffic.
Which Simulators Use Which Patternโ
| Simulator | Pattern | Why |
|---|---|---|
| ns-3 | System-Wide | One script, one global topology, one NSBSimClient |
| OMNeT++ | Per-Node | Each host module is independent, each needs its own NSBSimClient |
Go Deeperโ
- ns-3 Overview โ System-Wide mode in practice
- OMNeT++ Overview โ Per-Node mode in practice
- Architecture โ Simulator Modes โ the same patterns explained at the architecture level
- Configuration โ Simulator Modes โ the
simulator_modeYAML field