Skip to content

Commit

Permalink
Deflake total sum of full synchronizations
Browse files Browse the repository at this point in the history
Deflake test "PSYNC2: total sum of full synchronizations at least 4"
Explaination: during the prior test "PSYNC2: generate load while killing
replication links" load is generated on the master, and the replica's
connection is killed multiple times. On busy machine this load can force
the replica to full sync. There is no guarantee that the replicas will
find the necessary bytes in the COB.

Signed-off-by: naglera <[email protected]>
  • Loading branch information
naglera committed Jun 10, 2024
1 parent 95a753b commit 9b2b352
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/integration/psync2.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -290,14 +290,17 @@ start_server {} {
show_cluster_status
}

test "PSYNC2: total sum of full synchronizations is exactly 4" {
test "PSYNC2: total sum of full synchronizations at least 4" {
# During the setup, four full syncs were performed. It is also possible that one
# of the disconnected replicas may be forced to full sync during the
# 'generate load while killing replication links' test.
set sum 0
for {set j 0} {$j < 5} {incr j} {
incr sum [status $R($j) sync_full]
}
if {$sum != 4} {
show_cluster_status
assert {$sum == 4}
assert {$sum >= 4}
}
}

Expand Down

0 comments on commit 9b2b352

Please sign in to comment.