Class LeastLongTermMessageRate

    • Constructor Summary

      Constructors 
      Constructor Description
      LeastLongTermMessageRate​(org.apache.pulsar.broker.ServiceConfiguration conf)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Optional<java.lang.String> selectBroker​(java.util.Set<java.lang.String> candidates, BundleData bundleToAssign, LoadData loadData, org.apache.pulsar.broker.ServiceConfiguration conf)
      Find a suitable broker to assign the given bundle to.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LeastLongTermMessageRate

        public LeastLongTermMessageRate​(org.apache.pulsar.broker.ServiceConfiguration conf)
    • Method Detail

      • selectBroker

        public java.util.Optional<java.lang.String> selectBroker​(java.util.Set<java.lang.String> candidates,
                                                                 BundleData bundleToAssign,
                                                                 LoadData loadData,
                                                                 org.apache.pulsar.broker.ServiceConfiguration conf)
        Find a suitable broker to assign the given bundle to.
        Specified by:
        selectBroker in interface ModularLoadManagerStrategy
        Parameters:
        candidates - The candidates for which the bundle may be assigned.
        bundleToAssign - The data for the bundle to assign.
        loadData - The load data from the leader broker.
        conf - The service configuration.
        Returns:
        The name of the selected broker as it appears on ZooKeeper.