You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "lhotari (via GitHub)" <gi...@apache.org> on 2026/07/26 18:53:16 UTC

Re: [PR] [fix][broker] Fix AvgShedder assignment cache keying with stable bundle names [pulsar]

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


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/loadbalance/ModularLoadManagerStrategy.java:
##########
@@ -46,6 +46,26 @@ public interface ModularLoadManagerStrategy {
     Optional<String> selectBroker(Set<String> candidates, BundleData bundleToAssign, LoadData loadData,
             ServiceConfiguration conf);
 
+    /**
+     * Find a suitable broker to assign the given bundle when its stable name is available.
+     *
+     * @param candidates
+     *            The candidates for which the bundle may be assigned.
+     * @param bundle
+     *            The stable bundle name.
+     * @param bundleToAssign
+     *            The data for the bundle to assign.
+     * @param loadData
+     *            The load data from the leader broker.
+     * @param conf
+     *            The service configuration.
+     * @return The name of the selected broker as it appears on ZooKeeper.

Review Comment:
   the name of the broker is called `brokerId`, returned by org.apache.pulsar.broker.PulsarService#getBrokerId



-- 
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-unsubscribe@pulsar.apache.org

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