rust-server-sdk icon indicating copy to clipboard operation
rust-server-sdk copied to clipboard

Expose connection state to client consumers

Open aalexandrov opened this issue 3 years ago • 3 comments

Is your feature request related to a problem? Please describe.

At Materialize, we plan to use LaunchDarkly in continuously running processes and would like to have an internal metric indicating a state where the client instance temporary could not communicate with the LaunchDarkly service.

Describe the solution you'd like

Some method on the client instance that returns a bool or an enum indicates whether the client is connected and the connection is alive.

Describe alternatives you've considered Periodically polling LaunchDarkly API in a separate process / Tokio task.

Additional context

As a cloud service that is meant to be used in critical business applications, it is important to have good visibility for all our external dependencies.

aalexandrov avatar Dec 13 '22 11:12 aalexandrov

Thank you for filing this feature request. We have an internal ticket (sc-142483) tracking support for this feature. We will update this issue when the feature has been released.

keelerm84 avatar Dec 13 '22 18:12 keelerm84

Thanks! @aalexandrov, correct me if I'm wrong, but I think even better than a bool would be the time of the last successful synchronization, or the last successful connection heartbeat—whatever makes sense given the design of the internals of the library.

benesch avatar Dec 17 '22 17:12 benesch

@benesch yes a timestamp would be better.

aalexandrov avatar Dec 19 '22 10:12 aalexandrov