1
0
mirror of https://github.com/google/gops.git synced 2024-11-27 08:31:17 +02:00
gops/agent
Tobias Klauser 268f11e4fc agent: allow to set SO_REUSEPORT on listening socket
Introduce Option.SocketReuseAddrAndPort which, if set, will lead to the
SO_REUSEPORT socket option being set on the listening socket on
Unix-like OSes. This also sets SO_REUSEADDR which is already the default
in net.Listen (see net.setDefaultSockopts).

Setting these options increases the chance to re-bind() to the same
address and port upon agent restart if Options.Addr is set.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2020-12-09 19:27:52 +01:00
..
agent_test.go agent: allow to set SO_REUSEPORT on listening socket 2020-12-09 19:27:52 +01:00
agent.go agent: allow to set SO_REUSEPORT on listening socket 2020-12-09 19:27:52 +01:00
sockopt_unix.go agent: allow to set SO_REUSEPORT on listening socket 2020-12-09 19:27:52 +01:00
sockopt_unsupported.go agent: allow to set SO_REUSEPORT on listening socket 2020-12-09 19:27:52 +01:00