I - Vertex index valueV - Vertex valueE - Edge valuepublic class HashRangePartitionerFactory<I extends org.apache.hadoop.io.WritableComparable,V extends org.apache.hadoop.io.Writable,E extends org.apache.hadoop.io.Writable> extends GraphPartitionerFactory<I,V,E>
| Constructor and Description |
|---|
HashRangePartitionerFactory() |
| Modifier and Type | Method and Description |
|---|---|
int |
getPartition(I id,
int partitionCount,
int workerCount)
Calculates in which partition current vertex belongs to,
from interval [0, partitionCount).
|
int |
getWorker(int partition,
int partitionCount,
int workerCount)
Calculates worker that should be responsible for passed partition.
|
createMasterGraphPartitioner, createWorkerGraphPartitioner, getPartitionInRange, getPartitionInRange, initializegetConf, setConfclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetConfsetConfpublic int getPartition(I id, int partitionCount, int workerCount)
GraphPartitionerFactorygetPartition in class GraphPartitionerFactory<I extends org.apache.hadoop.io.WritableComparable,V extends org.apache.hadoop.io.Writable,E extends org.apache.hadoop.io.Writable>id - Vertex idpartitionCount - Number of partitionsworkerCount - Number of workerspublic int getWorker(int partition,
int partitionCount,
int workerCount)
GraphPartitionerFactorygetWorker in class GraphPartitionerFactory<I extends org.apache.hadoop.io.WritableComparable,V extends org.apache.hadoop.io.Writable,E extends org.apache.hadoop.io.Writable>partition - Current partitionpartitionCount - Number of partitionsworkerCount - Number of workersCopyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.