Skip to content

Commit

Permalink
Add a 5s delay after unblackholing (for the catch-up to work)
Browse files Browse the repository at this point in the history
Shorten the wait time for the open connection to expire to 5s
  • Loading branch information
henrybear327 committed Apr 25, 2024
1 parent a4404b3 commit f478b17
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/e2e/blackhole_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ func blackholeTestByMockingPartition(t *testing.T, clusterSize int, partitionLea
proxy.BlackholeTx()
proxy.BlackholeRx()

t.Logf("Wait 20s for any open connections to expire")
time.Sleep(20 * time.Second)
t.Logf("Wait 5s for any open connections to expire")
time.Sleep(5 * time.Second)

t.Logf("Wait for new leader election with remaining members")
leaderEPC := epc.Procs[waitLeader(t, epc, mockPartitionNodeIndex)]
Expand All @@ -83,6 +83,7 @@ func blackholeTestByMockingPartition(t *testing.T, clusterSize int, partitionLea
proxy.UnblackholeRx()

leaderEPC = epc.Procs[epc.WaitLeader(t)]
time.Sleep(5 * time.Second)
assertRevision(t, leaderEPC, 21)
assertRevision(t, partitionedMember, 21)
}
Expand Down

0 comments on commit f478b17

Please sign in to comment.