private static void filterOutHugeSubqueries(Subqueries subqueries) {
        Iterator<Integer> iterator = subqueries.subqueries.iterator();
        while (iterator.hasNext()) {
            Integer subquery = iterator.next();
            Set<Feature> values = subqueries.valuesForSubquery.get(subquery);
            Set<Feature> ranges = subqueries.rangesForSubquery.get(subquery);
            int sizeValues = values == null ? 0 : values.size();
            int sizeRanges = ranges == null ? 0 : ranges.size();
            if (sizeValues + sizeRanges > MAX_NUMBER_OF_TERMS) {
                iterator.remove();
                subqueries.valuesForSubquery.remove(subquery);
                subqueries.rangesForSubquery.remove(subquery);
            }
        }
    }
Converts a targeting query (the format provided by targeting team) into a file of Vespa queries formatted as URLs.

The format is the following:
- Each line represents one bulk query (upto 64 subqueries)
- Each bulk query has a set of subqueries separated by ";"
- Each subquery is of the format: attrName\tattrValue\tsubqueryIndex\tisRangeTerm;
- Some attributes have no value.
- Value may contain ";"

@author bjorncs
predicate-search/src/main/java/com/yahoo/search/predicate/utils/TargetingQueryFileConverter.java