Class PageRank.SimplePageRankWorkerContext
- java.lang.Object
-
- org.apache.giraph.conf.DefaultImmutableClassesGiraphConfigurable<I,V,E>
-
- org.apache.giraph.worker.WorkerAggregatorDelegator<org.apache.hadoop.io.WritableComparable,org.apache.hadoop.io.Writable,org.apache.hadoop.io.Writable>
-
- org.apache.giraph.worker.WorkerContext
-
- com.alibaba.graphscope.example.giraph.PageRank.SimplePageRankWorkerContext
-
- All Implemented Interfaces:
org.apache.giraph.aggregators.AggregatorUsage,org.apache.giraph.conf.GiraphConfigurationSettable<org.apache.hadoop.io.WritableComparable,org.apache.hadoop.io.Writable,org.apache.hadoop.io.Writable>,org.apache.giraph.conf.ImmutableClassesGiraphConfigurable<org.apache.hadoop.io.WritableComparable,org.apache.hadoop.io.Writable,org.apache.hadoop.io.Writable>,org.apache.giraph.worker.WorkerAggregatorUsage,org.apache.giraph.worker.WorkerBroadcastUsage,org.apache.giraph.worker.WorkerGlobalCommUsage,org.apache.giraph.worker.WorkerIndexUsage<org.apache.hadoop.io.WritableComparable>,org.apache.giraph.worker.WorkerReduceUsage,org.apache.hadoop.io.Writable
- Enclosing class:
- PageRank
public static class PageRank.SimplePageRankWorkerContext extends WorkerContext
Worker context used withPageRank.
-
-
Constructor Summary
Constructors Constructor Description SimplePageRankWorkerContext()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static doublegetFinalMax()static doublegetFinalMin()static longgetFinalSum()voidpostApplication()Finalize the WorkerContext.voidpostSuperstep()Execute user code.voidpreApplication()Initialize the WorkerContext.voidpreSuperstep()Execute user code.-
Methods inherited from class org.apache.giraph.worker.WorkerContext
aggregate, getAggregatedValue, getAndClearMessagesFromOtherWorkers, getContext, getMyWorkerIndex, getSuperstep, getTotalNumEdges, getTotalNumVertices, getWorkerCount, getWorkerForVertex, incStep, logToCommandLine, readFields, reduce, reduceMerge, sendMessageToWorker, setAggregatorManager, setCurStep, setFragment, write
-
Methods inherited from class org.apache.giraph.worker.WorkerAggregatorDelegator
getBroadcast
-
-
-
-
Method Detail
-
getFinalMax
public static double getFinalMax()
-
getFinalMin
public static double getFinalMin()
-
getFinalSum
public static long getFinalSum()
-
preApplication
public void preApplication() throws InstantiationException, IllegalAccessExceptionDescription copied from class:WorkerContextInitialize the WorkerContext. This method is executed once on each Worker before the first superstep starts.- Specified by:
preApplicationin classWorkerContext- Throws:
InstantiationException- Expected instantiation in this method.IllegalAccessException- Thrown for getting the class
-
postApplication
public void postApplication()
Description copied from class:WorkerContextFinalize the WorkerContext. This method is executed once on each Worker after the last superstep ends.- Specified by:
postApplicationin classWorkerContext
-
preSuperstep
public void preSuperstep()
Description copied from class:WorkerContextExecute user code. This method is executed once on each Worker before each superstep starts.- Specified by:
preSuperstepin classWorkerContext
-
postSuperstep
public void postSuperstep()
Description copied from class:WorkerContextExecute user code. This method is executed once on each Worker after each superstep ends.- Specified by:
postSuperstepin classWorkerContext
-
-