crossoverJie commented on code in PR #1255:
URL: https://github.com/apache/pulsar-client-go/pull/1255#discussion_r1690889316


##########
pulsar/client_impl.go:
##########
@@ -66,8 +66,10 @@ func newClient(options ClientOptions) (Client, error) {
        if connectionMaxIdleTime == 0 {
                connectionMaxIdleTime = defaultConnMaxIdleTime
        } else if connectionMaxIdleTime > 0 && connectionMaxIdleTime < 
minConnMaxIdleTime {
-               return nil, newError(InvalidConfiguration, 
fmt.Sprintf("Connection max idle time should be at least %f "+
-                       "seconds", minConnMaxIdleTime.Seconds()))
+               logger.Warnf("Connection idle detect interval seconds default 
same as max idle seconds, but max idle"+
+                       " seconds less than %d, to avoid checking"+
+                       " connection status too much, use default value : %d", 
minConnMaxIdleTime.Minutes(), minConnMaxIdleTime.Minutes())
+               connectionMaxIdleTime = minConnMaxIdleTime

Review Comment:
   Thank you for your explanatition, it as is might be a good choice as weel.



-- 
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.

To unsubscribe, e-mail: commits-unsubscr...@pulsar.apache.org

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

Reply via email to