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/main/java/org/elasticsearch/common/Rounding.java
instant = previousTransitionInstant.minusNanos(1_000_000);
                }
            }
            private Instant truncateAsLocalTime(Instant instant, final ZoneRules rules) {
                assert unitRoundsToMidnight == false : "truncateAsLocalTime should not be called if unitRoundsToMidnight";
                LocalDateTime localDateTime = LocalDateTime.ofInstant(instant, timeZone);
                final LocalDateTime truncatedLocalDateTime = truncateLocalDateTime(localDateTime);
                final List<ZoneOffset> currentOffsets = rules.getValidOffsets(truncatedLocalDateTime);
                if (currentOffsets.isEmpty() == false) {
                    
                    for (int offsetIndex = currentOffsets.size() - 1; offsetIndex >= 0; offsetIndex--) {
                        final Instant result = truncatedLocalDateTime.atOffset(currentOffsets.get(offsetIndex)).toInstant();
                        if (result.isAfter(instant) == false) {
                            return result;
                        }
                    }
                    assert false : "rounded time not found for " + instant + " with " + this;
                    return null;
                } else {
                    
                    
                    return null;
                }
            }
            @Override
            public String toString() {
                return TimeUnitRounding.this + "[java.time to " + unitMillis + "]";
            }
        }
        private abstract class AbstractNotToMidnightRounding extends TimeUnitPreparedRounding {