lhotari commented on code in PR #22541:
URL: https://github.com/apache/pulsar/pull/22541#discussion_r1574241817


##########
pulsar-client-admin-api/src/main/java/org/apache/pulsar/client/admin/PulsarAdminBuilder.java:
##########
@@ -336,4 +336,30 @@ PulsarAdminBuilder authentication(String 
authPluginClassName, Map<String, String
      *                              requests
      */
     PulsarAdminBuilder acceptGzipCompression(boolean acceptGzipCompression);
+
+    /**
+     * Configures the maximum number of connections that the client library 
will establish with a single host.
+     * <p>
+     * By default, the connection pool maintains up to 16 connections to a 
single host. This method allows you to
+     * modify this default behavior and limit the number of connections.
+     * <p>
+     * This setting can be useful in scenarios where you want to limit the 
resources used by the client library,
+     * or control the level of parallelism for operations so that a single 
client does not overwhelm
+     * the Pulsar cluster with too many concurrent connections.
+     *
+     * @param connectionsPerHost the maximum number of connections to 
establish per host. Set to <= 0 to disable
+     *                             the limit.
+     * @return the PulsarAdminBuilder instance, allowing for method chaining
+     */
+    PulsarAdminBuilder connectionsPerHost(int connectionsPerHost);

Review Comment:
   makes sense. renamed



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