protected abstract class GoraEdgeInputFormat.GoraEdgeReader extends EdgeReader<I,E>
Modifier | Constructor and Description |
---|---|
protected |
GoraEdgeReader() |
Modifier and Type | Method and Description |
---|---|
void |
close()
Finishes the reading process.
|
Edge<I,E> |
getCurrentEdge()
Gets current edge.
|
float |
getProgress()
Gets the progress of reading results from Gora.
|
protected void |
getResults()
Performs a range query to a Gora data store.
|
void |
initialize(org.apache.hadoop.mapreduce.InputSplit inputSplit,
org.apache.hadoop.mapreduce.TaskAttemptContext context)
Use the input split and context to setup reading the edges.
|
boolean |
nextEdge()
Gets the next edge from Gora data store.
|
protected abstract Edge<I,E> |
transformEdge(Object goraObject)
Parser for a single Gora object
|
getCurrentSourceId
aggregate, getAggregatedValue, getBroadcast, reduce, reduceMerge, setWorkerGlobalCommUsage
getConf, setConf
public void initialize(org.apache.hadoop.mapreduce.InputSplit inputSplit, org.apache.hadoop.mapreduce.TaskAttemptContext context) throws IOException, InterruptedException
EdgeReader
initialize
in class EdgeReader<I extends org.apache.hadoop.io.WritableComparable,E extends org.apache.hadoop.io.Writable>
inputSplit
- Input split to be used for reading edges.context
- Context from the task.IOException
InterruptedException
public boolean nextEdge() throws IOException, InterruptedException
nextEdge
in class EdgeReader<I extends org.apache.hadoop.io.WritableComparable,E extends org.apache.hadoop.io.Writable>
IOException
- exceptions passed along.InterruptedException
- exceptions passed along.public float getProgress() throws IOException, InterruptedException
getProgress
in class EdgeReader<I extends org.apache.hadoop.io.WritableComparable,E extends org.apache.hadoop.io.Writable>
IOException
InterruptedException
public Edge<I,E> getCurrentEdge() throws IOException, InterruptedException
getCurrentEdge
in class EdgeReader<I extends org.apache.hadoop.io.WritableComparable,E extends org.apache.hadoop.io.Writable>
IOException
InterruptedException
protected abstract Edge<I,E> transformEdge(Object goraObject)
goraObject
- vertex represented as a GoraObjectprotected void getResults()
public void close() throws IOException
close
in class EdgeReader<I extends org.apache.hadoop.io.WritableComparable,E extends org.apache.hadoop.io.Writable>
IOException
Copyright © 2011-2019 The Apache Software Foundation. All Rights Reserved.