RoundRobinKeyIndexStrategy implements
    PartitionIndexStrategy<MultiDimensionalNumericData, MultiDimensionalNumericData> { @Override public byte[][] getInsertionPartitionKeys(final MultiDimensionalNumericData insertionData) { position = (position + 1) % keys.length; return new byte[][] {keys[position]}; } RoundRobinKeyIndexStrategy();  RoundRobinKeyIndexStrategy(final int size); @Override String getId(); @Override byte[] toBinary(); @Override void fromBinary(final byte[] bytes); byte[][] getPartitionKeys(); @Override int getPartitionKeyLength(); @Override List<IndexMetaData> createMetaData(); @Override byte[][] getInsertionPartitionKeys(final MultiDimensionalNumericData insertionData); @Override byte[][] getQueryPartitionKeys(
      final MultiDimensionalNumericData queryData,
      final IndexMetaData... hints); @Override byte[][] getPredefinedSplits(); public int position; }
@Test public void testUniformityAndLargeKeySet() { final RoundRobinKeyIndexStrategy strategy = new RoundRobinKeyIndexStrategy(512); final Map<ByteArray, Integer> countMap = new HashMap<>(); for (int i = 0; i < 2048; i++) { final byte[][] ids = strategy.getInsertionPartitionKeys(sfcIndexedRange); assertEquals(1, ids.length); final ByteArray key = new ByteArray(ids[0]); if (countMap.containsKey(key)) { countMap.put(key, countMap.get(key) + 1); } else { countMap.put(key, 1); } } for (final Integer i : countMap.values()) { assertEquals(4, i.intValue()); } }