Skip to content

Commit

Permalink
Clear transient cluster setting at the end of the test
Browse files Browse the repository at this point in the history
Remove check of non zero assertion of time as it is non deterministic
Signed-off-by: Gaurav Bafna <[email protected]>
  • Loading branch information
gbbafna committed May 3, 2024
1 parent ed33488 commit 24d986c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,9 @@ public void testCreateCloneIndex() {
.cluster()
.prepareUpdateSettings()
.setTransientSettings(
Settings.builder().put(EnableAllocationDecider.CLUSTER_ROUTING_REBALANCE_ENABLE_SETTING.getKey(), (String) null)
Settings.builder()
.put(EnableAllocationDecider.CLUSTER_ROUTING_REBALANCE_ENABLE_SETTING.getKey(), (String) null)
.put(RecoverySettings.INDICES_INTERNAL_REMOTE_UPLOAD_TIMEOUT.getKey(), (String) null)
)
.get();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -582,9 +582,7 @@ private void assertNoDownloadStats(boolean nonZeroUploadTime) {
assertEquals(0, remoteTranslogTransferTracker.getDownloadBytesSucceeded());
assertEquals(0, remoteTranslogTransferTracker.getTotalDownloadsSucceeded());
assertEquals(0, remoteTranslogTransferTracker.getLastSuccessfulDownloadTimestamp());
if (nonZeroUploadTime) {
assertNotEquals(0, remoteTranslogTransferTracker.getTotalDownloadTimeInMillis());
} else {
if (nonZeroUploadTime == false) {
assertEquals(0, remoteTranslogTransferTracker.getTotalDownloadTimeInMillis());
}
}
Expand Down

0 comments on commit 24d986c

Please sign in to comment.