JSwitch Sim Java Switch Simulator Stanford HighPerformance Networking














- Slides: 14
JSwitch. Sim – Java Switch Simulator Stanford High-Performance Networking Group Paul Tarjan Nick Mckeown
What is JSwitch. Sim? ● ● Network switch simulator Not a topology simulator (like ns 2) (Although it could be with plugins) Allows experimentation with other algorithms and data structures Replacement and upgrade for Sim (written in C, by Nick)
What is JSwitch. Sim? (2) ● ● Object-oriented modular design Easily pluggable Either event based (Calendar Queue) or sequential time progression Has a GUI or configuration file based (GUI can save to config files)
Program Structure ● Very similar structure to SIM
Program Structure (2) ● ● ● ● ● Traffic : Generates Traffic Splitter : Creates fixed sized cells from packets Input Action : Moves cells to the Input Queues : An n x m matrix of FIFO queues (where n is # of inputs and m is # of outputs) Algorithm : Decides how to configure fabric Fabric : Moves the data from Input Queues to Output Queues using the Algorithm's output Output Queue : m FIFO queues (m is # of outputs) Output Action : Takes cells from the Output Queues and disposes of them Stats : Records statistics
Code Structure ● ● ● Everything implements Event Helper Classes Default. Event, Repeatable. Sim. Event All plugin classes extend Repeatable. Sim. Event To create plugins extend the corresponding abstract class and implement the abstract method (saving in the corresponding folder) For example: Algorithms extend algorithm. Algorithm and implement get. Matrix() saved in the folder “algorithm”
Code Structure (2) ● ● ● Each run of the program instantiates all new plugins (don't worry about state) Main method : common. Main Parser : common. Parser Gui : common. Gui Iterating loop (or queue executer) : common. Global. Data All Global Data : common. Global. Data. globaldata
Benchmark – Sequential Events Bernoulli IID 0. 5 prob Traffic
Benchmark – Unordered Events Bernoulli IID 0. 5 prob Traffic
Benchmark – Ordered Queued Events Bernoulli IID 0. 5 prob Traffic
Benchmark – Java vs C
Benchmark – SIM vs JSIM (bare)
Demo ● ● Just run “java common. Main” or use the jar Uses java 1. 5
Future Work ● ● Need tons of plugins to be built This is where you can come in!