Max max = (Max) maxAggs;
maxValue = max.getValue();
}
return maxValue;
}
<BUG>public static <T> List<T> getAll(String index, String type, Class<T> clazz) throws Exception {
</BUG>
final SearchResponse response = Common.elasticsearchClient.
prepareSearch(index).
<BUG>setTypes(type).
setQuery(QueryBuilders.</BUG>
matchAllQuery()).

Max max = (Max) maxAggs;
maxValue = max.getValue();
}
return maxValue;
}
public static <T> List<T> getAll(String index, String type, Class<T> clazz, String filterTermKey, String filterTermValue) throws Exception {
final SearchResponse response = Common.elasticsearchClient.
prepareSearch(index).
setTypes(type).
setSearchType(SearchType.DFS_QUERY_THEN_FETCH).
setPostFilter(QueryBuilders.termQuery(filterTermKey, filterTermValue).buildAsBytes()).
setSize(Integer.MAX_VALUE).
setQuery(QueryBuilders.
matchAllQuery()).
