address cr

This commit is contained in:
fjy 2014-06-16 14:07:10 -07:00
parent d2cf7d3f0a
commit 08c88e8fb7
1 changed files with 4 additions and 3 deletions

View File

@ -21,6 +21,7 @@ package io.druid.query.timeboundary;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.google.common.base.Charsets;
import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableMap;
import com.google.common.collect.Lists; import com.google.common.collect.Lists;
import com.google.common.collect.Maps; import com.google.common.collect.Maps;
@ -123,10 +124,10 @@ public class TimeBoundaryQuery extends BaseQuery<Result<TimeBoundaryResultValue>
public byte[] getCacheKey() public byte[] getCacheKey()
{ {
final byte[] excludeBytes = bound.getBytes(); final byte[] boundBytes = bound.getBytes(Charsets.UTF_8);
return ByteBuffer.allocate(1 + excludeBytes.length) return ByteBuffer.allocate(1 + boundBytes.length)
.put(CACHE_TYPE_ID) .put(CACHE_TYPE_ID)
.put(excludeBytes) .put(boundBytes)
.array(); .array();
} }