SIGN IN SIGN UP

enhancement(networking): Implement TCP keepalive `time` configuration (#5157)

* enhancement(networking): Implement TCP keepalive configuration for incoming connections

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* enhancement(networking): Implement TCP keepalive configuration for outgoing connections

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Implement constructor for socket config with full options

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* fix(networking): Implement (de)serializing TCP keepalive duration fields from u64

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Test TCP keepalive config on syslog source

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* docs(networking): Document current state of TCP keepalive support

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Express computation more succinctly with .map (clippy)

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Remove .clone() on copy type (clippy)

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Test partial/empty TCP keepalive config

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Add keepalive docs

Signed-off-by: binarylogic <bjohnson@binarylogic.com>

* chore(networking): Fix usage of make_tcp_config -> make_basic_tcp_config

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Clarify keepalive parameters

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Lift restriction of feature flag, since function is used in other contexts

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Remove default values for TCP keepalive config, as they only are suggestions

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Clarify wording in TCP keepalive description

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Add keepalive docs to all relevant sources and sinks

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(external docs): Remove docs for  and  TCP keepalive options, as they are not supported yet

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Use TcpSinkConfig::new and make fields private

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Join serde attributes

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Change TCP keepalive configurations from duration to _sec value

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Clean up SocketConfig/SocketSinkConfig constructors

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Fix missing import without listenfd feature

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Remove unused keepalive interval_secs / retries options

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Simplify closure (clippy)

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Introduce sources-utils-tcp-keepalive feature flag

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

* chore(networking): Unwrap keepalive config from caller

Signed-off-by: Pablo Sichert <mail@pablosichert.com>

Co-authored-by: binarylogic <bjohnson@binarylogic.com>
P
Pablo Sichert committed
2593d91b729e014abc4c8d2a79f6d4128e82baf6
Parent: d4b7b30
Committed by GitHub <noreply@github.com> on 12/4/2020, 8:34:25 PM