@Override
  public HostToKeyMapper<Integer> getAllPartitionsMultipleHosts(URI serviceUri, int numHostPerPartition)
      throws ServiceUnavailableException
  {
    return getHostToKeyMapper(serviceUri, null, numHostPerPartition, null);
  }
@Test(dataProvider = "ringFactories")
  public void testAllPartitionMultipleHostsStickKey(RingFactory<URI> ringFactory) throws URISyntaxException, ServiceUnavailableException
  {
    int numHost = 2;
    URI serviceURI = new URI("d2://articles");

    ConsistentHashKeyMapper mapper = getConsistentHashKeyMapper(ringFactory);

    String myStickyKey = "sticky";
    HostToKeyMapper<Integer> result = mapper.getAllPartitionsMultipleHosts(serviceURI, numHost, myStickyKey);
    Map<Integer, List<URI>> originalOrderingOfHost = getOrderingOfHostsForEachKey(result, numHost);

    // repeat 100 times. The ordering of the hosts should always be the same because of sticky key
    int numOfMatch = 0;
    for (int i = 0; i < 100; i++)
    {
      result = mapper.getAllPartitionsMultipleHosts(serviceURI, numHost, myStickyKey);
      Map<Integer, List<URI>> newOrderingOfHost = getOrderingOfHostsForEachKey(result, numHost);
      if (newOrderingOfHost.equals(originalOrderingOfHost))
      {
        numOfMatch++;
      }
    }
    Assert.assertEquals(100, numOfMatch);
  }