use of no.nav.pto.veilarbportefolje.domene.FacetResults in project veilarbportefolje by navikt.
the class OpensearchService method hentPortefoljestorrelser.
public FacetResults hentPortefoljestorrelser(String enhetId) {
SearchSourceBuilder request = byggPortefoljestorrelserQuery(enhetId);
PortefoljestorrelserResponse response = search(request, indexName.getValue(), PortefoljestorrelserResponse.class);
List<Bucket> buckets = response.getAggregations().getFilter().getSterms().getBuckets();
return new FacetResults(buckets);
}
Aggregations