Small protection against a high number of nodes in UpdateMappingTests.updateMappingConcurrently

This commit is contained in:
Boaz Leskes 2013-08-14 16:23:53 +02:00
parent 256bf1f4bc
commit 3eed2625e2

View File

@ -247,8 +247,10 @@ public class UpdateMappingTests extends AbstractSharedClusterTest {
// Test that we can concurrently update different indexes and types.
// NOTE: concurrently updating the mapping of the same type and index can still return before all (relevant) nodes are updated.
// The fix for that tracked on issues #3508
createIndex("test1");
createIndex("test2");
int shardNo = Math.max(5, numberOfNodes());
prepareCreate("test1").setSettings("index.number_of_shards", shardNo).execute().actionGet();
prepareCreate("test2").setSettings("index.number_of_shards", shardNo).execute().actionGet();
final Throwable[] threadException = new Throwable[1];
final AtomicBoolean stop = new AtomicBoolean(false);