build-coordinator/src/main/java/org/jboss/pnc/coordinator/builder/BuildQueue.java
public synchronized void addWaitingTask(BuildTask task, Runnable taskReadyCallback) {
        unfinishedTasks.add(task);
        log.debug("adding waiting task: {}", task);
        waitingTasksWithCallbacks.put(task, taskReadyCallback);
    }
public synchronized void addWaitingTask(BuildTask task, Runnable taskReadyCallback) {
        unfinishedTasks.add(task);
        log.debug("adding waiting task: {}", task);
        waitingTasksWithCallbacks.put(task, taskReadyCallback);
    }
Add a task that is waiting for dependencies
@param task task that is not ready to build
@param taskReadyCallback a callback to be invoked when the task becomes ready