Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Simone Rossi
main
Commits
39748fdc
Commit
39748fdc
authored
May 17, 2018
by
Daniele Venzano
Browse files
Add consistency check for service counts
parent
80020a4f
Changes
1
Hide whitespace changes
Inline
Side-by-side
zoe_master/preprocessing.py
View file @
39748fdc
...
...
@@ -46,6 +46,10 @@ def _digest_application_description(state: SQLManager, execution: Execution):
for
service_descr
in
execution
.
description
[
'services'
]:
essential_count
=
service_descr
[
'essential_count'
]
total_count
=
service_descr
[
'total_count'
]
if
essential_count
>
total_count
:
execution
.
set_error
()
execution
.
set_error_message
(
'total_count is less than essential_count for service {}'
.
format
(
service_descr
[
'name'
]))
return
False
elastic_count
=
total_count
-
essential_count
counter
=
0
for
service_n_
in
range
(
essential_count
):
...
...
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