From 1b56169bd414a7247a2fafb6cc872e38567849d8 Mon Sep 17 00:00:00 2001 From: Arved Solth Date: Tue, 19 Oct 2021 13:50:44 +0200 Subject: [PATCH] Replace deprecated aggregation order key '_term' with '_key' --- .../org/kitodo/production/services/data/base/SearchService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kitodo/src/main/java/org/kitodo/production/services/data/base/SearchService.java b/Kitodo/src/main/java/org/kitodo/production/services/data/base/SearchService.java index 3c53b925253..58fb0094dd0 100644 --- a/Kitodo/src/main/java/org/kitodo/production/services/data/base/SearchService.java +++ b/Kitodo/src/main/java/org/kitodo/production/services/data/base/SearchService.java @@ -857,7 +857,7 @@ protected List findDistinctValues(QueryBuilder query, String field, bool List distinctValues = new ArrayList<>(); try { TermsAggregationBuilder termsAggregation = AggregationBuilders.terms(field).field(field) - .order(BucketOrder.aggregation("_term", sort)); + .order(BucketOrder.aggregation("_key", sort)); if (size > 0) { termsAggregation.size(Math.toIntExact(size)); }