Skip to content

Commit bf8819d

Browse files
authored
Fix testRepositoryAnalysis (#69538)
This test would occasionally generate an invalid request in which the max total data size cannot be satisfied. This commit ensures the max total data size is always sufficiently large. Relates #67247 Closes #69219
1 parent df74efb commit bf8819d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

x-pack/plugin/snapshot-repo-test-kit/src/internalClusterTest/java/org/elasticsearch/repositories/blobstore/testkit/RepositoryAnalysisSuccessIT.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@ protected Collection<Class<? extends Plugin>> nodePlugins() {
6666
return List.of(TestPlugin.class, LocalStateCompositeXPackPlugin.class, SnapshotRepositoryTestKit.class);
6767
}
6868

69-
@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/69219")
7069
public void testRepositoryAnalysis() {
7170

7271
createRepositoryNoVerify("test-repo", TestPlugin.ASSERTING_REPO_TYPE);
@@ -99,7 +98,9 @@ public void testRepositoryAnalysis() {
9998
}
10099

101100
if (usually()) {
102-
request.maxTotalDataSize(new ByteSizeValue(between(1, 1 << 20)));
101+
request.maxTotalDataSize(
102+
new ByteSizeValue(request.getMaxBlobSize().getBytes() + request.getBlobCount() - 1 + between(0, 1 << 20))
103+
);
103104
blobStore.ensureMaxTotalBlobSize(request.getMaxTotalDataSize().getBytes());
104105
}
105106

0 commit comments

Comments
 (0)