harness / ff-dotnet-server-sdk

.net Server SDK for integrating with Harness Feature Flag service.
https://harness.io/
Apache License 2.0
5 stars 10 forks source link

FFM-6877 - Dropped SSE connections are not being detected #53

Closed andybharness closed 1 year ago

andybharness commented 1 year ago

FFM-6877 - Dropped SSE connections are not being detected

What SSE EventSource does not detect that a connection may have dropped. This update removes calls to StreamReader's EndOfStream/ReadLineAsync which will hang forever if the socket has no data arriving. Instead, read and parse the lines directly from the SSE source and add a CancellationTokenSource with a timeout of 60 seconds, if no data arrives.

Why We're getting customer reports of flags not updating correctly when the SDK has been left running for some time.

Testing Added new Wiremock tests for testing EventSource, also manual testing

swarmia[bot] commented 1 year ago

✅  Linked to Bug FFM-6877 · Customer getting inconsistent values from the .NET SDK