Skip to content

Commit 790810e

Browse files
authored
More concurrency in repo analysis integ tests (#138414)
Since #133633 these testclusters-based tests set `node.processors: 2`, and since they also set `-Xmx512m` the resulting nodes only have a single snapshot thread so the repo analysis tests do not meaningfully exercise concurrent operations any more (at least for repositories that have blocking implementations of their CAS operations). This commit adds more snapshot threads to these tests to reinstate the lost coverage.
1 parent b5cc1c4 commit 790810e

File tree

6 files changed

+6
-0
lines changed

6 files changed

+6
-0
lines changed

x-pack/plugin/snapshot-repo-test-kit/qa/azure/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/AzureRepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ private static Predicate<String> decideAuthHeaderPredicate() {
7474
private static final ElasticsearchCluster cluster = ElasticsearchCluster.local()
7575
.module("repository-azure")
7676
.module("snapshot-repo-test-kit")
77+
.setting("thread_pool.snapshot.max", "10")
7778
.keystore("azure.client.repository_test_kit.account", AZURE_TEST_ACCOUNT)
7879
.keystore("azure.client.repository_test_kit.key", () -> AZURE_TEST_KEY, s -> Strings.hasText(AZURE_TEST_KEY))
7980
.keystore("azure.client.repository_test_kit.sas_token", () -> AZURE_TEST_SASTOKEN, s -> Strings.hasText(AZURE_TEST_SASTOKEN))

x-pack/plugin/snapshot-repo-test-kit/qa/gcs/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/GCSRepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ public class GCSRepositoryAnalysisRestIT extends AbstractRepositoryAnalysisRestT
3131
private static ElasticsearchCluster cluster = ElasticsearchCluster.local()
3232
.module("repository-gcs")
3333
.module("snapshot-repo-test-kit")
34+
.setting("thread_pool.snapshot.max", "10")
3435
.setting("gcs.client.repository_test_kit.endpoint", () -> fixture.getAddress(), s -> USE_FIXTURE)
3536
.setting("gcs.client.repository_test_kit.token_uri", () -> fixture.getAddress() + "/o/oauth2/token", s -> USE_FIXTURE)
3637
.apply(c -> {

x-pack/plugin/snapshot-repo-test-kit/qa/hdfs/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/HdfsRepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ public class HdfsRepositoryAnalysisRestIT extends AbstractHdfsRepositoryAnalysis
2424
public static ElasticsearchCluster cluster = ElasticsearchCluster.local()
2525
.distribution(DistributionType.DEFAULT)
2626
.plugin("repository-hdfs")
27+
.setting("thread_pool.snapshot.max", "10")
2728
.setting("xpack.license.self_generated.type", "trial")
2829
.setting("xpack.security.enabled", "false")
2930
.build();

x-pack/plugin/snapshot-repo-test-kit/qa/hdfs/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/SecureHdfsRepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ public class SecureHdfsRepositoryAnalysisRestIT extends AbstractHdfsRepositoryAn
3131
public static ElasticsearchCluster cluster = ElasticsearchCluster.local()
3232
.distribution(DistributionType.DEFAULT)
3333
.plugin("repository-hdfs")
34+
.setting("thread_pool.snapshot.max", "10")
3435
.setting("xpack.license.self_generated.type", "trial")
3536
.setting("xpack.security.enabled", "false")
3637
.systemProperty("java.security.krb5.conf", () -> krb5Fixture.getConfPath().toString())

x-pack/plugin/snapshot-repo-test-kit/qa/minio/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/MinioRepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ public class MinioRepositoryAnalysisRestIT extends AbstractRepositoryAnalysisRes
3131
.distribution(DistributionType.DEFAULT)
3232
.keystore("s3.client.repository_test_kit.access_key", "s3_test_access_key")
3333
.keystore("s3.client.repository_test_kit.secret_key", "s3_test_secret_key")
34+
.setting("thread_pool.snapshot.max", "10")
3435
.setting("s3.client.repository_test_kit.endpoint", minioFixture::getAddress)
3536
.setting("xpack.security.enabled", "false")
3637
.setting("xpack.ml.enabled", "false")

x-pack/plugin/snapshot-repo-test-kit/qa/s3/src/javaRestTest/java/org/elasticsearch/repositories/blobstore/testkit/analyze/S3RepositoryAnalysisRestIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ private static void ensurePurposeParameterPresent(S3HttpHandler.S3Request reques
8282
.setting("s3.client.repo_test_kit.region", regionSupplier, (n) -> USE_FIXTURE)
8383
.setting("s3.client.repo-test_kit.add_purpose_custom_query_parameter", () -> randomFrom("true", "false"), n -> randomBoolean())
8484
.setting("xpack.security.enabled", "false")
85+
.setting("thread_pool.snapshot.max", "10")
8586
.build();
8687

8788
@ClassRule

0 commit comments

Comments
 (0)