connection

Version

Socket level settings for connections to a backend: how long the client waits while connecting and while reading, how long an idle connection is kept in the pool, and which local network interface it binds to.

Syntax

connection:
keepAliveTimeout: <int>
localAddr: <string>
soTimeout: <int>
timeout: <int>
connection:
  keepAliveTimeout: <int>
  localAddr: <string>
  soTimeout: <int>
  timeout: <int>

Attributes

NameRequiredDefaultDescriptionExamples
keepAliveTimeoutfalse4000Time in milliseconds before an idle connection is closed and removed from the connection pool. Should be less than the server-side keep-alive timeout. If a response includes a "Keep-Alive" header, that value overrides this setting.30000
localAddrfalse(not set)IP address of the local network interface to use for outbound connections. Useful in multi-homed environments.192.168.1.42
soTimeoutfalse0Read timeout in milliseconds. Applies to reading from the socket after the connection is established. A value of 0 means infinite timeout.10000
timeoutfalse10000Maximum time in milliseconds to wait when establishing a TCP connection. A value of 0 may block indefinitely depending on the system.5000

Can be used in