Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
CONF
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
UvA
CONF
Commits
af9d245f
Commit
af9d245f
authored
Jan 30, 2018
by
Spiros Koulouzis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reduce number of VMs
parent
8077df69
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
dum_planner.py
drip_planner2/src/planner/dum_planner.py
+4
-1
dum_planner.pyc
drip_planner2/src/planner/dum_planner.pyc
+0
-0
No files found.
drip_planner2/src/planner/dum_planner.py
View file @
af9d245f
...
@@ -102,6 +102,7 @@ class DumpPlanner:
...
@@ -102,6 +102,7 @@ class DumpPlanner:
def
plan
(
self
,
max_vms
):
def
plan
(
self
,
max_vms
):
network_templates
=
self
.
get_network_templates
()
network_templates
=
self
.
get_network_templates
()
vms
=
[]
vms
=
[]
print
network_templates
if
network_templates
and
network_templates
[
'network'
]
and
network_templates
[
'network'
][
'multicast'
]
==
True
:
if
network_templates
and
network_templates
[
'network'
]
and
network_templates
[
'network'
][
'multicast'
]
==
True
:
vm
=
{}
vm
=
{}
vm
[
'name'
]
=
'id'
vm
[
'name'
]
=
'id'
...
@@ -158,7 +159,9 @@ class DumpPlanner:
...
@@ -158,7 +159,9 @@ class DumpPlanner:
vm
[
'scaling_mode'
]
=
'single'
vm
[
'scaling_mode'
]
=
'single'
vms
.
append
(
vm
)
vms
.
append
(
vm
)
if
max_vms
<=
-
1
:
max_vms
=
len
(
vms
)
//
3
if
max_vms
>
-
1
and
len
(
vms
)
>
max_vms
:
if
max_vms
>
-
1
and
len
(
vms
)
>
max_vms
:
vms
=
self
.
sort_vms
(
vms
,
max_vms
)
vms
=
self
.
sort_vms
(
vms
,
max_vms
)
return
vms
return
vms
drip_planner2/src/planner/dum_planner.pyc
View file @
af9d245f
No preview for this file type
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