Commit c1f1cbb2 authored by Iustin Pop's avatar Iustin Pop
Browse files

Fix ordering of instance/nodes

After the locking changes, and the partial locking of nodes, the
instance/node list is not ordered anymore. Reorder so that it behaves as
before.

Reviewed-by: ultrotter
parent bf766476
......@@ -1476,6 +1476,8 @@ class LUQueryNodes(NoHooksLU):
"Some nodes were removed before retrieving their data: %s" % missing)
else:
nodenames = all_info.keys()
nodenames = utils.NiceSort(nodenames)
nodelist = [all_info[name] for name in nodenames]
# begin data gathering
......@@ -2664,6 +2666,8 @@ class LUQueryInstances(NoHooksLU):
% missing)
else:
instance_names = all_info.keys()
instance_names = utils.NiceSort(instance_names)
instance_list = [all_info[iname] for iname in instance_names]
# begin data gathering
......
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