Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
net: use the same default TCPKeepAlive interval in net.Listen and net.Dial #31510
In #23378 (comment) we noted that there is a mismatch between the default TCP keepalive used by
For uniformity, it would be advisable to ensure these two defaults match.
If there are no counter-proposals, my suggestion would be to use 15s as the interval (see #23459 for prior discussion).
An explicit non-goal of this issue is that of making the default value part of the API. For the reasons discussed in https://go-review.googlesource.com/c/go/+/107196 this should remain undefined, and users that have specific requirements in terms of exact keepalive durations should specify a custom configuration.