You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/08/25 07:23:27 UTC

[GitHub] [pulsar-client-go] jonyhy96 commented on a change in pull request #360: [Issue 257][feat] Support limit the retry number of reconnectToBroker

jonyhy96 commented on a change in pull request #360:
URL: https://github.com/apache/pulsar-client-go/pull/360#discussion_r476231877



##########
File path: pulsar/consumer.go
##########
@@ -140,6 +140,9 @@ type ConsumerOptions struct {
 
 	// A chain of interceptors, These interceptors will be called at some points defined in ConsumerInterceptor interface.
 	Interceptors ConsumerInterceptors
+
+	// MaxReconnectToBroker set the maximum retry number of reconnectToBroker. (default: ultimate)
+	MaxReconnectToBroker *uint

Review comment:
       > IMO using `int` type is more friendly, the default value `0` represents unlimited.
   
   How aboud `0` represents no retry but nil means retry ultimate times? Then this changes won't break current behavior of reconnectToBroker.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org