This is the code for class Switches from
https://github.com/osrg/ryu/blob/master/ryu/topology/switches.py#L429

The member variables of particular interest to me in the class Switches are
the following.

        self.dps = {}                 # datapath_id => Datapath class
        self.port_state = {}          # datapath_id => ports
        self.ports = PortDataState()  # Port class -> PortData class
        self.links = LinkState()      # Link class -> timestamp
        self.is_active = True

These are the member variables that the RYU uses to cache the topology
details.I am trying to figure out how a topology can be represented using
the following variables.

1) dps is a dictionary which maps datapath_id to datapath class?

               - Can someone explain to me what is a datapath_id and a
datapath class?

2) port_state is a dictionary which maps datapath id to ports

               -  As per my understanding on a switch without a VLAN all
the ports will belong to the same datapath id? In case of a switch with
VLAN ports on the switch can have multiple datapath id's. Is my
understanding correct?

3) ports is again a dictionary which maps Port class to PortData class?

                - what does this mean?

4) links is again a dictionary which maps Link class to timestamp

                - again what does this mean?

I am trying to get my head around how RYU controller stores the topology
information using the above structures.Any help in understanding or
explanation would be greatly appreciated.

Thanks & Regards,
Karthik.
------------------------------------------------------------------------------
Start Your Social Network Today - Download eXo Platform
Build your Enterprise Intranet with eXo Platform Software
Java Based Open Source Intranet - Social, Extensible, Cloud Ready
Get Started Now And Turn Your Intranet Into A Collaboration Platform
http://p.sf.net/sfu/ExoPlatform
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to