agave-jobs/jobs-core/src/main/java/org/iplantc/service/jobs/managers/JobManager.java
/**
     * Finds queue on the given executionSystem that supports the given number of nodes and
     * memory per node given.
     *
     * @param nodes a positive integer value or -1 for no limit
     * @param processors positive integer value or -1 for no limit
     * @param memory memory in GB or -1 for no limit
     * @param requestedTime time in hh:mm:ss format
     * @return a BatchQueue matching the given parameters or null if no match can be found
     */
Finds queue on the given executionSystem that supports the given number of nodes and
memory per node given.


Finds queue on the given executionSystem that supports the given number of nodes and memory per node given .
public static BatchQueue selectQueue(ExecutionSystem executionSystem, Long nodes, Double memory, Long processors, String requestedTime) {
        if (validateBatchSubmitParameters(executionSystem.getDefaultQueue(), nodes, processors, memory, requestedTime)) {
            return executionSystem.getDefaultQueue();
        } else {
            BatchQueue[] queues = executionSystem.getBatchQueues().toArray(new BatchQueue[]{});
            Arrays.sort(queues);
            for (BatchQueue queue : queues) {
                if (queue.isSystemDefault())
                    continue;
                else if (validateBatchSubmitParameters(queue, nodes, processors, memory, requestedTime))
                    return queue;
            }
        }
        return null;
    }
public static BatchQueue selectQueue ( ExecutionSystem executionSystem , Long nodes , Double memory , Long processors , String requestedTime ) { if ( validateBatchSubmitParameters ( executionSystem . getDefaultQueue ( ) , nodes , processors , memory , requestedTime ) ) { return executionSystem . getDefaultQueue ( ) ; } else { BatchQueue [ ] queues = executionSystem . getBatchQueues ( ) . toArray ( new BatchQueue [ ] { } ) ; Arrays . sort ( queues ) ; for ( BatchQueue queue : queues ) { if ( queue . isSystemDefault ( ) ) continue ; else if ( validateBatchSubmitParameters ( queue , nodes , processors , memory , requestedTime ) ) return queue ; } } return null ; }
Finds queue on the given executionSystem that supports the given number of nodes and
 memory per node given.
Finds queue on the given executionSystem that supports the given number of nodes and memory per node given .