fsprojects / pulsar-client-dotnet

Apache Pulsar native client for .NET (C#/F#/VB)
MIT License
301 stars 47 forks source link

expose the connection state to consumer and producer interface #239 #240

Closed baumerik closed 10 months ago

baumerik commented 10 months ago

Hi @Lanayx,

here is my attempt for exposing the IsConnected. For the MultiTopicsConsumerImpl and the PartitionedProducerImpl I've assumed that it will be return true just when all Topics are connected and ready. I've tested it localy it with the MultiTopicsConsumerImpl and the property switched es expected. please give me feedback if it fits to your expectation.

Thanks Erik

Lanayx commented 10 months ago

Thanks for the PR, it looks good! Can you please also add it to the Reader interface and implementation, just like in Java code

baumerik commented 10 months ago

Thanks for the PR, it looks good! Thanks for my first Feedback to F# 😄

Can you please also add it to the Reader interface and implementation, just like in Java code sorry, this i haven't see in the first time. It is now added.

Lanayx commented 10 months ago

Merged! Do you want to do this for 3.0 branch as well? 2.x will not receive performance updates and refactoring in future

Lanayx commented 10 months ago

https://www.nuget.org/packages/Pulsar.Client/2.15.0 - this was published