Add helper to delete elastic work queue consumers#46
Conversation
Add `DeletePcgElasticWorkQueueConsumerAsync` to support faster recovery when using ephemeral member name. Keep `DeletePcgElasticMembersAsync` unchanged so its behavior remains consistent with similar APIs in other language clients.
jnmoyne
left a comment
There was a problem hiding this comment.
Thanks for the contribution but I don't believe this would be a good change to merge. Reason being that you should not need to have a new call just to speed up membership changes (when you remove a member), for example if you do it too fast after the change to the KV record with the membership some instances of the member may be slightly behind in getting the KV's update and would re-create it.
If you want to make membership changes and failover times to be tighter, in Go this is done by calculating the PinnedTTL, inactive threshold and pull expiry from the provided AckWait value, which can then be lowered down to 1s, improving reactivity from the current defaults and values used by the .NET library.
I think this should be closed and instead a new PR should be created to port the changes related to calculating timeout values from the AckWait value like in Go. See synadia-io/orbit.go#45
|
Thanks for your reply, This is found to be an issued when we were doing a rolling update of a group of consumers. If calculating timeout from AckWait could bring down failover time to sub-second timeframe, then that sound a better way to go. |
|
AckWait, pinned TTL, and fetch timeout are all related, hence the improvement in the Go version to derive all these timings from the AckWait value. However the JetStream Consume() used underneath the covers only allows you to lower the fetch timeout down to 1s so that is going to be the lower limit of how low you can make those timings. Should still be a lot more responsive than with the current timings which are pretty relaxed. |
Add
DeletePcgElasticWorkQueueConsumerAsyncto support faster recovery when using ephemeral member name.Keep
DeletePcgElasticMembersAsyncunchanged so its behavior remains consistent with similar APIs in other language clients.