You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This routing approach is specific for spine-leaf topology
14
11
"""
12
+
15
13
def__init__(self, topo):
16
14
Routing.__init__(self, topo)
17
-
#self.numOfServers = topo.numOfServers
18
-
#self.serverPerRack = topo.serverPerRack
19
-
#self.numOfToRs = topo.numOfToRs
20
-
#self.numOfCores = topo.numOfCores
21
-
self.topo=topo
15
+
#self.numOfServers = topo.numOfServers
16
+
#self.serverPerRack = topo.serverPerRack
17
+
#self.numOfToRs = topo.numOfToRs
18
+
#self.numOfCores = topo.numOfCores
19
+
self.topo=topo
22
20
23
21
defBuildAllPath(self):
24
22
self.CalculateAllPath()
25
23
26
24
defBuildPath(self, srcId, dstId, flow, flows):
27
25
self.CalculatePath(srcId, dstId, flow, flows)
28
26
29
-
# def CalculateAllPath(self):
30
-
# """
31
-
# This function calculate path between each pair of servers by choosing a core switch with least traversing flows. For spine-leaf, choosing a path is essentially choosing a spine to travers
32
-
# """
33
-
# for srcId in range(1, self.numOfServers + 1):
34
-
# #gc.collect()
35
-
# for dstId in range(1, self.numOfServers + 1):
36
-
# self.CalculatePath(srcId=srcId, dstId=dstId)
27
+
# def CalculateAllPath(self):
28
+
# """
29
+
# This function calculate path between each pair of servers by choosing a core switch with least traversing flows. For spine-leaf, choosing a path is essentially choosing a spine to travers
0 commit comments