public int getRequiredTaskCount() {
        final int requiredTasks = requiredQueueSize - totalQueuedCount.get();
        // because of async processing it is possible to go below zero, but hide that from the caller
        return Math.max(requiredTasks, 0);
    }
Get the number of tasks we would still like to create if possible. This is the number of tasks configured as the
target queue size minus the number of tasks we have already found or added to the queue as we are examining each
associated filter in priority order.

@return The number of tasks we would still like to add to the queue.
stroom-processor/stroom-processor-impl/src/main/java/stroom/processor/impl/QueueProcessTasksState.java