I keep getting an Unsupported Aggregation error for anything but "terms".
I'm building aggregations like:
AggregationBuilders.filter(name).filter(FilterBuilders.wrapperFilter("[WRAPPED FILTER SOURCE]"));
And adding it to the search with SearchRequestBuilder's addAggregation
When I use a terms aggregation, it works fine and returns buckets as expected. But a filter or range gives org.elasticsearch.search.aggregations.bucket.filter.InternalFilter as an unsupported.
The strange thing is running the query (the one that the Java API gives on a to string) through the REST endpoint works fine.