mirror of https://github.com/apache/druid.git
fix caching bug with search query limits
This commit is contained in:
parent
47ec240703
commit
d208b535a6
|
@ -27,6 +27,7 @@ import com.google.common.collect.Iterables;
|
||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import com.google.common.collect.Ordering;
|
import com.google.common.collect.Ordering;
|
||||||
import com.google.common.collect.Sets;
|
import com.google.common.collect.Sets;
|
||||||
|
import com.google.common.primitives.Ints;
|
||||||
import com.metamx.common.IAE;
|
import com.metamx.common.IAE;
|
||||||
import com.metamx.common.ISE;
|
import com.metamx.common.ISE;
|
||||||
import com.metamx.common.guava.MergeSequence;
|
import com.metamx.common.guava.MergeSequence;
|
||||||
|
@ -177,6 +178,7 @@ public class SearchQueryQueryToolChest extends QueryToolChest<Result<SearchResul
|
||||||
final ByteBuffer queryCacheKey = ByteBuffer
|
final ByteBuffer queryCacheKey = ByteBuffer
|
||||||
.allocate(1 + granularityBytes.length + filterBytes.length + querySpecBytes.length + dimensionsBytesSize)
|
.allocate(1 + granularityBytes.length + filterBytes.length + querySpecBytes.length + dimensionsBytesSize)
|
||||||
.put(SEARCH_QUERY)
|
.put(SEARCH_QUERY)
|
||||||
|
.put(Ints.toByteArray(query.getLimit()))
|
||||||
.put(granularityBytes)
|
.put(granularityBytes)
|
||||||
.put(filterBytes)
|
.put(filterBytes)
|
||||||
.put(querySpecBytes);
|
.put(querySpecBytes);
|
||||||
|
|
Loading…
Reference in New Issue