summaryrefslogtreecommitdiff
path: root/core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java')
-rw-r--r--core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java b/core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java
index 8b79b78397..6f3fdee36d 100644
--- a/core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java
+++ b/core/src/test/java/org/elasticsearch/cluster/ClusterStateDiffIT.java
@@ -46,6 +46,7 @@ import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.transport.LocalTransportAddress;
import org.elasticsearch.discovery.DiscoverySettings;
import org.elasticsearch.gateway.GatewayService;
+import org.elasticsearch.index.Index;
import org.elasticsearch.index.query.QueryBuilders;
import org.elasticsearch.index.shard.ShardId;
import org.elasticsearch.test.ESIntegTestCase;
@@ -223,11 +224,11 @@ public class ClusterStateDiffIT extends ESIntegTestCase {
* Randomly updates index routing table in the cluster state
*/
private IndexRoutingTable randomIndexRoutingTable(String index, String[] nodeIds) {
- IndexRoutingTable.Builder builder = IndexRoutingTable.builder(index);
+ IndexRoutingTable.Builder builder = IndexRoutingTable.builder(new Index(index, "_na_"));
int shardCount = randomInt(10);
for (int i = 0; i < shardCount; i++) {
- IndexShardRoutingTable.Builder indexShard = new IndexShardRoutingTable.Builder(new ShardId(index, i));
+ IndexShardRoutingTable.Builder indexShard = new IndexShardRoutingTable.Builder(new ShardId(index, "_na_", i));
int replicaCount = randomIntBetween(1, 10);
for (int j = 0; j < replicaCount; j++) {
UnassignedInfo unassignedInfo = null;