Skip to content

Commit

Permalink
docs: http2 ping-timeout clarification (#4420)
Browse files Browse the repository at this point in the history
  • Loading branch information
jroper authored Sep 9, 2024
1 parent a38c01e commit 4fbcbe4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions akka-http-core/src/main/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,8 @@ akka.http {
ping-interval = 0s

# Fail the connection if a sent ping is not acknowledged within this timeout.
# When zero the ping-interval is used, if set the value must be evenly divisible by less than or equal to the ping-interval.
# When set to zero, the ping-interval is used. Otherwise, the value must be less than or equal to the ping-interval, and must be a
# divisor of the ping-interval.
ping-timeout = 0s

# Limit the number of RSTs a client is allowed to do on one connection, per interval
Expand Down Expand Up @@ -486,7 +487,8 @@ akka.http {
ping-interval = 0s

# Fail the connection if a sent ping is not acknowledged within this timeout.
# When zero the ping-interval is used, if set the value must be evenly divisible by less than or equal to the ping-interval.
# When set to zero, the ping-interval is used. Otherwise, the value must be less than or equal to the ping-interval, and must be a
# divisor of the ping-interval.
ping-timeout = 0s

# The maximum number of times a connections is attempted
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ private[http] object Http2CommonSettings {
if (pingInterval > Duration.Zero && pingTimeout > Duration.Zero) {
require(
pingTimeout <= pingInterval && pingInterval.toMillis % pingTimeout.toMillis == 0,
s"ping-timeout must be less than and evenly divisible by the ping-interval ($pingInterval)")
s"ping-timeout must be less than or equal to and a divisor of the ping-interval ($pingInterval)")
}
}
}
Expand Down

0 comments on commit 4fbcbe4

Please sign in to comment.