Idea #7676
Updated by Brett Smith about 9 years ago
Sort available nodes by their cost first, number of cores second. Use the first available node(s) in that list.
Where nodes_available_for_job_now calls Node.find_each, generate a list of available nodes and sort them according to the above criteria. Iterate that list with the current loop as-is.