Connection lost from client


#1

After setting heartbeat to very low… it still lost connection. please see the log below -> It tries only 3 times after 4th one it lost connection to changes feed.

Heartbeat: heartbeat written to _changes feed for request received (as GUEST)
2018-05-17T13:40:12.133-04:00 Heartbeat: heartbeat written to _changes feed for request received (as GUEST)
2018-05-17T13:40:37.134-04:00 Heartbeat: heartbeat written to _changes feed for request received (as GUEST)
2018-05-17T13:41:02.114-04:00 Changes+: Client connection lost: (as GUEST)
2018-05-17T13:41:02.114-04:00 Changes+: Notifying to check for _changes feed termination
2018-05-17T13:41:02.114-04:00 Changes: MultiChangesFeed done

Code as below ->

var getChangesRequest = new GetChangesRequest
{
Feed = ChangesFeed.Continuous,
Since = seq.ToString(),
Style = ChangesStyle.AllDocs,
IncludeDocs = true,
Timeout = 0,
Heartbeat = 13000
};
try
{
IObservable observable = client.Changes.ObserveContinuous(getChangesRequest, _Cancellation.Token);
observable.Subscribe(new MyObserver()
{
InterceptOnNext = data =>
{
seq++;
ProcessData(data);
},
InterceptOnError = e =>
{
WriteLog(e.Message + " " + seq);
},
});

Is there any setting which is preventing to keep changes feed alive?


#2

There is one strange behavior…I dropped heartbeat all the way to 1 second… it still send heartbeat in 25-26 seconds.

Is that possible bug in sync gateway not to record heatbeat at all?