Right now filter aggregations run in "compatible" mode if the top level query is `bool: {filter: { match_all: {}}}}` - but this really just just `match_all` in disguise. We should just run in filter-by-filter mode here.
server/src/test/java/org/elasticsearch/search/aggregations/bucket/filter/FiltersAggregatorTests.java
.entry(
                            "filters",
                            matchesList().item(
                                matchesMap().entry("query", "*:*").entry("specialized_for", "match_all").entry("results_from_metadata", 0)
                            )
                        )
                );
            }
        }
    }
    public void testComplexUnionDisabledFilterByFilter() throws IOException {
        MappedFieldType dft = new DateFieldMapper.DateFieldType(
            "date",
            true,
            false,
            false,
            DateFieldMapper.DEFAULT_DATE_TIME_FORMATTER,
            Resolution.MILLISECONDS,
            null,
            null,
            Collections.emptyMap()
        );
        MappedFieldType kft = new KeywordFieldType("kwd");
        AggregationBuilder builder = new FiltersAggregationBuilder(
            "test",
            new KeyedFilter("q1", new RangeQueryBuilder("date").from("2020-01-01").to("2020-03-01").includeUpper(false))
        );
        debugTestCase(builder, new TermQuery(new Term("kwd", "a")), iw -> {
            iw.addDocument(
                List.of(