Do not release the executor inside `_check_child_processes
`
The method ``ProcessMonitor._check_child_processes`` was releasing the thread executor inside a method that creates a lock for the resource "_check_child_processes". Despite this resource is not used anywhere else (at least for this instance), this could lead to a potential deadlock. The current implementation of ``lockutils.synchronized`` with the default value "external=False" and "fair=False" is a ``threading.Lock()`` instance. The goal of this lock is, precisely, to execute the code inside the locked code without any interruption and then to be able to release the executor. Closes-Bug: #2073743 Change-Id: I44c7a4ce81a67b86054832ac050cf5b465727adf (cherry picked from commit baa57ab38d754bfa2dba488feb9429c1380d616c)
This commit is contained in:
parent
1f761c27f2
commit
c9b6982431
@ -272,7 +272,6 @@ class ProcessMonitor(object):
|
||||
'resource_type': self._resource_type,
|
||||
'uuid': service_id.uuid})
|
||||
self._execute_action(service_id)
|
||||
eventlet.sleep(0)
|
||||
|
||||
def _periodic_checking_thread(self):
|
||||
while self._monitor_processes:
|
||||
|
Loading…
x
Reference in New Issue
Block a user