Skip to content

Commit

Permalink
chore: Fix failing HTTP/2 retry test #4205
Browse files Browse the repository at this point in the history
  • Loading branch information
johanandren committed May 4, 2023
1 parent fb44051 commit c585db0
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,15 @@ abstract class Http2PersistentClientSpec(tls: Boolean) extends AkkaSpecWithMater
if (withBackoff) {
// not immediate when using backoff, 4 retries before failing, backoff is 300-800ms (so at least 1.2s)
client.responsesIn.expectNoMessage(clientSettings.http2Settings.baseConnectionBackoff * 4)
// total max backoff for 4 tries with the random factor could actually worst case be something
// like 600 + 800 + 800 + 800 - those 1200 ms = 1800 ms, but no way to pass a timeout to expectError
awaitAssert({
client.responsesIn.expectError()
}, 1800.millis)
} else {
// directly
client.responsesIn.expectError()
}
client.responsesIn.expectError()
client.requestsOut.expectCancellation()

}
Expand Down

0 comments on commit c585db0

Please sign in to comment.