diff --git a/extensions-contrib/time-min-max/src/main/java/io/druid/query/aggregation/TimestampAggregator.java b/extensions-contrib/time-min-max/src/main/java/io/druid/query/aggregation/TimestampAggregator.java index 78209b1acd6..cbfd20b4a27 100644 --- a/extensions-contrib/time-min-max/src/main/java/io/druid/query/aggregation/TimestampAggregator.java +++ b/extensions-contrib/time-min-max/src/main/java/io/druid/query/aggregation/TimestampAggregator.java @@ -26,7 +26,7 @@ import java.util.Comparator; public class TimestampAggregator implements Aggregator { - static final Comparator COMPARATOR = LongMaxAggregator.COMPARATOR; + static final Comparator COMPARATOR = Comparator.comparingLong(n -> ((Number) n).longValue()); static Object combineValues(Comparator comparator, Object lhs, Object rhs) {