Commit bad92e87 authored by Paul Rich's avatar Paul Rich
Browse files

Adding in RLock for nodes for the idle detection loop.

Make sure that an update cannot change this list midflight for a job.

Caller also holds this lock at this point in time.  The node_lock must
be reentrant!
parent e98d1429
......@@ -721,6 +721,7 @@ class CraySystem(BaseSystem):
node_id_list = []
if not requested_loc_in_forbidden:
raise ValueError("forbidden locations not in queue")
with self._node_lock:
for node_id in node_id_list: #strip non-idle nodes.
if not self.nodes[str(node_id)].status in ['idle']:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment