HCOLL-369 various fixes

This commit is contained in:
leventov
2015-07-25 23:54:17 +03:00
parent 27275fa5be
commit b88c821ea5
4 changed files with 7 additions and 5 deletions
@@ -56,7 +56,7 @@ public class KeySegmentDistributionTest {
for (int i = 0; i < size; i++) {
random.nextBytes(keyBytes);
String key = new String(keyBytes, StandardCharsets.US_ASCII);
long hash = LongHashFunction.murmur_3().hashBytes(StandardCharsets.UTF_8.encode(key));
long hash = LongHashFunction.city_1_1().hashBytes(StandardCharsets.UTF_8.encode(key));
int segmentIndex = (((int) hash) & Integer.MAX_VALUE) % segments;
// Put the segment index as a value to the map
map.put(key, segmentIndex);