类开关中我特别感兴趣的成员变量如下所示。在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
这些是RYU用来缓存拓扑细节的成员变量。在
1)dps是一个字典,它将datapath_id映射到datapath类?在
^{pr2}$
2)端口状态是将数据路径id映射到端口的字典- 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)端口又是一个字典,它将端口类映射到端口数据类?在- what does this mean?
4)links还是一个字典,它将Link类映射到时间戳- again what does this mean?
我想弄清楚RYU控制器是如何使用上面的方法存储拓扑信息的结构。任何如能帮助理解或解释,将不胜感激。在