Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
allgo
allgo
Commits
2bc17331
Commit
2bc17331
authored
Jan 31, 2017
by
BAIRE Anthony
Browse files
do not update sandbox state if ShuttingDown is raised
parent
194f06db
Changes
1
Hide whitespace changes
Inline
Side-by-side
docker/controller.py
View file @
2bc17331
...
@@ -317,6 +317,7 @@ class Manager:
...
@@ -317,6 +317,7 @@ class Manager:
"""
"""
self
.
_shutdown
=
asyncio
.
Future
()
self
.
_shutdown
=
asyncio
.
Future
()
self
.
_shutdown
.
set_exception
(
ShuttingDown
())
self
.
_shutdown
.
set_exception
(
ShuttingDown
())
self
.
_shutdown
.
exception
()
# to avoid asyncio warnings
# cancel all 'next' tasks
# cancel all 'next' tasks
for
hnd
in
self
.
_handles
.
values
():
for
hnd
in
self
.
_handles
.
values
():
if
hnd
.
nxt
is
not
None
:
if
hnd
.
nxt
is
not
None
:
...
@@ -724,6 +725,10 @@ EOF
...
@@ -724,6 +725,10 @@ EOF
phase
=
"commit"
phase
=
"commit"
yield
from
self
.
_manage_commit
(
webapp
,
commit_versions
)
yield
from
self
.
_manage_commit
(
webapp
,
commit_versions
)
except
ShuttingDown
:
next_state
=
None
log
.
info
(
"sandbox %r %s aborted (controller shutdown)"
,
webapp
.
docker_name
,
phase
)
except
BaseException
as
e
:
except
BaseException
as
e
:
next_state
=
fail_state
next_state
=
fail_state
...
...
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