Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pcom-laboratoare-public
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PCom
pcom-laboratoare-public
Commits
7f101ee6
Commit
7f101ee6
authored
1 year ago
by
Ion-Dorinel FILIP (25005)
Browse files
Options
Downloads
Patches
Plain Diff
Fixed definition of benchmark
parent
f17123c1
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lab5/topo.py
+4
-1
4 additions, 1 deletion
lab5/topo.py
with
4 additions
and
1 deletion
lab5/topo.py
+
4
−
1
View file @
7f101ee6
...
...
@@ -21,6 +21,7 @@ from mininet.node import Node
from
mininet.log
import
setLogLevel
,
info
from
mininet.cli
import
CLI
from
mininet.link
import
TCLink
import
time
import
sys
class
LinuxRouter
(
Node
):
...
...
@@ -68,11 +69,13 @@ class NetworkManager(object):
def
run_benchmark
(
self
):
server
=
self
.
h2
.
popen
(
"
./server
"
,
shell
=
True
)
# Give server some time to start
time
.
sleep
(
1
)
client
=
self
.
h1
.
popen
(
"
./client
"
,
shell
=
True
)
server
.
wait
()
print
(
"
##### Benchmark results #####
"
)
print
(
server
.
stdout
.
read
().
decode
().
strip
())
print
(
client
.
stdout
.
read
().
decode
().
strip
())
print
(
"
#############################
"
)
def
run
(
run_benchmark
=
False
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment