Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ycai
simbricks
Commits
21d7fb71
Commit
21d7fb71
authored
Jan 29, 2024
by
Antoine Kaufmann
Browse files
experiments: add support for specifying queue types to e2e
parent
bbfa0b25
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
0 deletions
+12
-0
experiments/simbricks/orchestration/e2e_components.py
experiments/simbricks/orchestration/e2e_components.py
+4
-0
experiments/simbricks/orchestration/e2e_topologies.py
experiments/simbricks/orchestration/e2e_topologies.py
+8
-0
No files found.
experiments/simbricks/orchestration/e2e_components.py
View file @
21d7fb71
...
@@ -192,6 +192,7 @@ class E2ESimpleChannel(E2ETopologyChannel):
...
@@ -192,6 +192,7 @@ class E2ESimpleChannel(E2ETopologyChannel):
self
.
type
=
"Simple"
self
.
type
=
"Simple"
self
.
data_rate
=
""
self
.
data_rate
=
""
self
.
queue_size
=
""
self
.
queue_size
=
""
self
.
queue_type
=
""
self
.
delay
=
""
self
.
delay
=
""
self
.
left_node
:
E2ETopologyNode
self
.
left_node
:
E2ETopologyNode
self
.
right_node
:
E2ETopologyNode
self
.
right_node
:
E2ETopologyNode
...
@@ -201,6 +202,7 @@ class E2ESimpleChannel(E2ETopologyChannel):
...
@@ -201,6 +202,7 @@ class E2ESimpleChannel(E2ETopologyChannel):
raise
AttributeError
(
f
"Not all nodes for channel
{
self
.
id
}
given"
)
raise
AttributeError
(
f
"Not all nodes for channel
{
self
.
id
}
given"
)
self
.
mapping
.
update
({
self
.
mapping
.
update
({
"DataRate"
:
self
.
data_rate
,
"DataRate"
:
self
.
data_rate
,
"QueueType"
:
self
.
queue_type
,
"QueueSize"
:
self
.
queue_size
,
"QueueSize"
:
self
.
queue_size
,
"Delay"
:
self
.
delay
,
"Delay"
:
self
.
delay
,
"LeftNode"
:
self
.
left_node
.
id
,
"LeftNode"
:
self
.
left_node
.
id
,
...
@@ -291,6 +293,7 @@ class E2ESimpleNs3Host(E2EHost):
...
@@ -291,6 +293,7 @@ class E2ESimpleNs3Host(E2EHost):
super
().
__init__
(
idd
)
super
().
__init__
(
idd
)
self
.
type
=
"SimpleNs3"
self
.
type
=
"SimpleNs3"
self
.
data_rate
=
""
self
.
data_rate
=
""
self
.
queue_type
=
""
self
.
queue_size
=
""
self
.
queue_size
=
""
self
.
delay
=
""
self
.
delay
=
""
self
.
congestion_control
:
CongestionControl
=
None
self
.
congestion_control
:
CongestionControl
=
None
...
@@ -303,6 +306,7 @@ class E2ESimpleNs3Host(E2EHost):
...
@@ -303,6 +306,7 @@ class E2ESimpleNs3Host(E2EHost):
cc
=
self
.
congestion_control
.
ns3
cc
=
self
.
congestion_control
.
ns3
self
.
mapping
.
update
({
self
.
mapping
.
update
({
"DataRate"
:
self
.
data_rate
,
"DataRate"
:
self
.
data_rate
,
"QueueType"
:
self
.
queue_type
,
"QueueSize"
:
self
.
queue_size
,
"QueueSize"
:
self
.
queue_size
,
"Delay"
:
self
.
delay
,
"Delay"
:
self
.
delay
,
"CongestionControl"
:
cc
,
"CongestionControl"
:
cc
,
...
...
experiments/simbricks/orchestration/e2e_topologies.py
View file @
21d7fb71
...
@@ -115,6 +115,7 @@ class DCFatTree(E2ETopology):
...
@@ -115,6 +115,7 @@ class DCFatTree(E2ETopology):
'n_agg_racks'
:
6
,
'n_agg_racks'
:
6
,
'h_per_rack'
:
40
,
'h_per_rack'
:
40
,
'mtu'
:
'1448'
,
'mtu'
:
'1448'
,
'queue_type'
:
'ns3::PTPQueue'
,
'spine_link_delay'
:
'1us'
,
'spine_link_delay'
:
'1us'
,
'spine_link_rate'
:
'100Gbps'
,
'spine_link_rate'
:
'100Gbps'
,
'spine_link_queue'
:
'512KB'
,
'spine_link_queue'
:
'512KB'
,
...
@@ -194,6 +195,7 @@ class DCFatTree(E2ETopology):
...
@@ -194,6 +195,7 @@ class DCFatTree(E2ETopology):
l
.
right_node
=
spine_sw
l
.
right_node
=
spine_sw
l
.
delay
=
self
.
params
[
'spine_link_delay'
]
l
.
delay
=
self
.
params
[
'spine_link_delay'
]
l
.
data_rate
=
self
.
params
[
'spine_link_rate'
]
l
.
data_rate
=
self
.
params
[
'spine_link_rate'
]
l
.
queue_type
=
self
.
params
[
'queue_type'
]
l
.
queue_size
=
self
.
params
[
'spine_link_queue'
]
l
.
queue_size
=
self
.
params
[
'spine_link_queue'
]
self
.
links
.
append
(
l
)
self
.
links
.
append
(
l
)
self
.
spine_agg_links
.
append
(
l
)
self
.
spine_agg_links
.
append
(
l
)
...
@@ -206,6 +208,7 @@ class DCFatTree(E2ETopology):
...
@@ -206,6 +208,7 @@ class DCFatTree(E2ETopology):
l
.
right_node
=
agg_sw
l
.
right_node
=
agg_sw
l
.
delay
=
self
.
params
[
'agg_link_delay'
]
l
.
delay
=
self
.
params
[
'agg_link_delay'
]
l
.
data_rate
=
self
.
params
[
'agg_link_rate'
]
l
.
data_rate
=
self
.
params
[
'agg_link_rate'
]
l
.
queue_type
=
self
.
params
[
'queue_type'
]
l
.
queue_size
=
self
.
params
[
'agg_link_queue'
]
l
.
queue_size
=
self
.
params
[
'agg_link_queue'
]
self
.
links
.
append
(
l
)
self
.
links
.
append
(
l
)
self
.
agg_tor_links
.
append
(
l
)
self
.
agg_tor_links
.
append
(
l
)
...
@@ -277,6 +280,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
...
@@ -277,6 +280,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
'link_rate'
:
'5Gbps'
,
'link_rate'
:
'5Gbps'
,
'link_delay'
:
'1us'
,
'link_delay'
:
'1us'
,
'link_queue_size'
:
'512KB'
,
'link_queue_size'
:
'512KB'
,
'link_queue_type'
:
'ns3::PTPQueue'
,
'congestion_control'
:
e2e
.
CongestionControl
.
CUBIC
,
'congestion_control'
:
e2e
.
CongestionControl
.
CUBIC
,
'app_stop_time'
:
'60s'
,
'app_stop_time'
:
'60s'
,
}
}
...
@@ -296,6 +300,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
...
@@ -296,6 +300,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
s_host
.
data_rate
=
params
[
'link_rate'
]
s_host
.
data_rate
=
params
[
'link_rate'
]
s_host
.
ip
=
s_ip
+
prefix
s_host
.
ip
=
s_ip
+
prefix
s_host
.
queue_size
=
params
[
'link_queue_size'
]
s_host
.
queue_size
=
params
[
'link_queue_size'
]
s_host
.
queue_type
=
params
[
'link_queue_type'
]
s_host
.
congestion_control
=
params
[
'congestion_control'
]
s_host
.
congestion_control
=
params
[
'congestion_control'
]
s_app
=
e2e
.
E2EPacketSinkApplication
(
'sink'
)
s_app
=
e2e
.
E2EPacketSinkApplication
(
'sink'
)
s_app
.
local_ip
=
'0.0.0.0:5000'
s_app
.
local_ip
=
'0.0.0.0:5000'
...
@@ -312,6 +317,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
...
@@ -312,6 +317,7 @@ def add_contig_bg(topo, subnet='10.42.0.0/16', **kwargs):
c_host
.
data_rate
=
params
[
'link_rate'
]
c_host
.
data_rate
=
params
[
'link_rate'
]
c_host
.
ip
=
c_ip
+
prefix
c_host
.
ip
=
c_ip
+
prefix
c_host
.
queue_size
=
params
[
'link_queue_size'
]
c_host
.
queue_size
=
params
[
'link_queue_size'
]
c_host
.
queue_type
=
params
[
'link_queue_type'
]
c_host
.
congestion_control
=
params
[
'congestion_control'
]
c_host
.
congestion_control
=
params
[
'congestion_control'
]
c_app
=
e2e
.
E2EBulkSendApplication
(
'sender'
)
c_app
=
e2e
.
E2EBulkSendApplication
(
'sender'
)
c_app
.
remote_ip
=
s_ip
+
':5000'
c_app
.
remote_ip
=
s_ip
+
':5000'
...
@@ -325,6 +331,7 @@ def add_homa_bg(topo, subnet='10.2.0.0/16', **kwargs):
...
@@ -325,6 +331,7 @@ def add_homa_bg(topo, subnet='10.2.0.0/16', **kwargs):
'link_rate'
:
'20Gbps'
,
'link_rate'
:
'20Gbps'
,
'link_delay'
:
'500ns'
,
'link_delay'
:
'500ns'
,
'link_queue_size'
:
'512KB'
,
'link_queue_size'
:
'512KB'
,
'link_queue_type'
:
'ns3::HomaPFifoQueue'
,
'app_stop_time'
:
'60s'
,
'app_stop_time'
:
'60s'
,
}
}
for
(
k
,
v
)
in
kwargs
.
items
():
for
(
k
,
v
)
in
kwargs
.
items
():
...
@@ -346,6 +353,7 @@ def add_homa_bg(topo, subnet='10.2.0.0/16', **kwargs):
...
@@ -346,6 +353,7 @@ def add_homa_bg(topo, subnet='10.2.0.0/16', **kwargs):
s_host
.
data_rate
=
params
[
'link_rate'
]
s_host
.
data_rate
=
params
[
'link_rate'
]
s_host
.
ip
=
ip
+
prefix
s_host
.
ip
=
ip
+
prefix
s_host
.
queue_size
=
params
[
'link_queue_size'
]
s_host
.
queue_size
=
params
[
'link_queue_size'
]
s_host
.
queue_type
=
params
[
'link_queue_type'
]
remotes_to_connect
=
random
.
choices
(
remotes
,
k
=
10
)
remotes_to_connect
=
random
.
choices
(
remotes
,
k
=
10
)
# print(remotes_to_connect)
# print(remotes_to_connect)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment