Affects Version/s: None
Fix Version/s: None
Support has reported issues running in Azure environments, where the Azure VM idle timeout appears to be killing connections that do not have a keep-alive configured.
In Sync Gateway 1.4, the fix for this (via go-couchbase) is to:
1. Call SetKeepAlive and SetKeepAlivePeriod on the memcached TCPConn.
2. Use the DefaultTransport as the starting point when creating an HTTPClient, to pick up the default DialContext settings. (https://golang.org/pkg/net/http/#RoundTripper)
I don't believe gocb currently supports either of the above two options.
For TCP, keep alive isn't being set:
For HTTP, gocb builds a custom transport from scratch that doesn't include DialContext settings:
From previous conversations with Brett Lawson, this may be by design on the TCP side, but I'd like to hear more specifics about why that's not needed to support something like the Azure environment.