|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.continuent.tungsten.replicator.storage.parallel.LoadBalancingPartitioner
public class LoadBalancingPartitioner
Partitions event by assigning to the least loaded queue.
| Constructor Summary | |
|---|---|
LoadBalancingPartitioner()
|
|
| Method Summary | |
|---|---|
PartitionerResponse |
partition(ReplDBMSHeader event,
int taskId)
Returns the partition with the smallest current size or the first partition that has a current size of zero. |
void |
setContext(PluginContext context)
Assigns the current runtime context in case the partitioner needs to refer to replicator state. |
void |
setPartitionMetadata(java.util.List<PartitionMetadata> partitions)
Sets metadata for partitions. |
void |
setPartitions(int availablePartitions)
Sets the number of available partitions. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LoadBalancingPartitioner()
| Method Detail |
|---|
public void setPartitions(int availablePartitions)
setPartitions in interface PartitioneravailablePartitions - Number of partitions availablePartitioner.setPartitions(int)public void setPartitionMetadata(java.util.List<PartitionMetadata> partitions)
setPartitionMetadata in interface StatefulPartitionerpartitions - List of partition metadata instancesStatefulPartitioner.setPartitionMetadata(java.util.List)public void setContext(PluginContext context)
setContext in interface Partitionercontext - Replicator runtime contextPartitioner.setContext(com.continuent.tungsten.replicator.plugin.PluginContext)
public PartitionerResponse partition(ReplDBMSHeader event,
int taskId)
partition in interface Partitionerevent - Event to be assigned a partitiontaskId - Task id of input thread
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||