Skip to content

Commit

Permalink
Remove random of recovery chunk size setting
Browse files Browse the repository at this point in the history
The recovery chunk size setting was injected in #58018, but too
aggressively and broke several tests. This change removes that
random injection.

Relates #58018
  • Loading branch information
dnhatn committed Jul 8, 2020
1 parent d2c5a4c commit e50a033
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,6 @@
import org.elasticsearch.indices.store.IndicesStore;
import org.elasticsearch.ingest.IngestMetadata;
import org.elasticsearch.node.NodeMocksPlugin;
import org.elasticsearch.node.RecoverySettingsChunkSizePlugin;
import org.elasticsearch.plugins.NetworkPlugin;
import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.rest.RestStatus;
Expand Down Expand Up @@ -2052,9 +2051,6 @@ protected Collection<Class<? extends Plugin>> getMockPlugins() {
mocks.add(MockFieldFilterPlugin.class);
}
}
if (randomBoolean()) {
mocks.add(RecoverySettingsChunkSizePlugin.class);
}
if (addMockTransportService()) {
mocks.add(getTestTransportPlugin());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
import org.elasticsearch.node.Node;
import org.elasticsearch.node.NodeService;
import org.elasticsearch.node.NodeValidationException;
import org.elasticsearch.node.RecoverySettingsChunkSizePlugin;
import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.script.ScriptModule;
import org.elasticsearch.script.ScriptService;
Expand Down Expand Up @@ -164,7 +163,6 @@
import static org.elasticsearch.test.ESTestCase.assertBusy;
import static org.elasticsearch.test.ESTestCase.getTestTransportType;
import static org.elasticsearch.test.ESTestCase.inFipsJvm;
import static org.elasticsearch.test.ESTestCase.randomBoolean;
import static org.elasticsearch.test.ESTestCase.randomFrom;
import static org.elasticsearch.test.NodeRoles.dataOnlyNode;
import static org.elasticsearch.test.NodeRoles.masterOnlyNode;
Expand Down Expand Up @@ -409,10 +407,6 @@ public InternalTestCluster(
RandomNumbers.randomIntBetween(random, 1, 5));
builder.put(RecoverySettings.INDICES_RECOVERY_MAX_CONCURRENT_OPERATIONS_SETTING.getKey(),
RandomNumbers.randomIntBetween(random, 1, 4));
if (mockPlugins.contains(RecoverySettingsChunkSizePlugin.class) && randomBoolean()) {
builder.put(RecoverySettingsChunkSizePlugin.CHUNK_SIZE_SETTING.getKey(),
new ByteSizeValue(RandomNumbers.randomIntBetween(random, 256, 10 * 1024 * 1024)));
}
defaultSettings = builder.build();
executor = EsExecutors.newScaling("internal_test_cluster_executor", 0, Integer.MAX_VALUE, 0, TimeUnit.SECONDS,
EsExecutors.daemonThreadFactory("test_" + clusterName), new ThreadContext(Settings.EMPTY));
Expand Down

0 comments on commit e50a033

Please sign in to comment.