类 BundleData
java.lang.Object
org.apache.pulsar.policies.data.loadbalancer.BundleData
Data class comprising the short term and long term historical data for this bundle.
-
构造器概要
构造器构造器说明BundleData(int numShortSamples, int numLongSamples) Initialize the bundle data.BundleData(int numShortSamples, int numLongSamples, NamespaceBundleStats defaultStats) Initialize this bundle data and have its histories default to the given stats before the first sample is received. -
方法概要
修饰符和类型方法说明intvoidsetLongTermData(TimeAverageMessageData longTermData) voidsetShortTermData(TimeAverageMessageData shortTermData) voidsetTopics(int topics) voidupdate(NamespaceBundleStats newSample) Update the historical data for this bundle.
-
构造器详细资料
-
BundleData
public BundleData() -
BundleData
public BundleData(int numShortSamples, int numLongSamples) Initialize the bundle data.- 参数:
numShortSamples- Number of short term samples to use.numLongSamples- Number of long term samples to use.
-
BundleData
Initialize this bundle data and have its histories default to the given stats before the first sample is received.- 参数:
numShortSamples- Number of short term samples to use.numLongSamples- Number of long term samples to use.defaultStats- The stats to default to before the first sample is received.
-
-
方法详细资料
-
update
Update the historical data for this bundle.- 参数:
newSample- The bundle stats to update this data with.
-
getShortTermData
-
setShortTermData
-
getLongTermData
-
setLongTermData
-
getTopics
public int getTopics() -
setTopics
public void setTopics(int topics)
-