Open fecet opened 1 month ago
Currently not. Java client does not have the similar feature as well. You'd like to make the reconnection backoff configurable, right? So you can manually delay the first reconnection.
However, it would affect the normal case. For example, if you configured it as 5 seconds, then even if the connection was disconnected due to some network issues, the consumer still required 5 seconds to recover.
IMO, a good idea is to add a new field to the protocol that tells the clients not to reconnect within some time. You can also add a discussion for the feature in https://lists.apache.org/list.html?dev@pulsar.apache.org
Could you provide an option to set the client's automatic reconnection strategy? I would like to use the admin API to force delete a subscription, but currently, the consumer immediately reconnects after being disconnected, causing the subscription to be recreated.
per https://github.com/apache/pulsar/pull/22423