GuaguaInputSplit@Deprecated public class GuaguaInputSplit extends org.apache.hadoop.mapreduce.InputSplit implements org.apache.hadoop.io.Writable
InputSplit implementation in guagua for Hadoop MapReduce job.
If mapper with isMaster true means it is master, for master so far fileSplits is
null.
For worker, input fileSplits are included, here FileSplit array is used to make guagua support
combining FileSplits in one task.
| Constructor and Description |
|---|
GuaguaInputSplit()
Deprecated.
Default constructor without any setting.
|
GuaguaInputSplit(boolean isMaster,
org.apache.hadoop.mapreduce.lib.input.FileSplit... fileSplits)
Deprecated.
Constructor with
isMaster and fileSplits settings. |
GuaguaInputSplit(boolean isMaster,
org.apache.hadoop.mapreduce.lib.input.FileSplit fileSplit)
Deprecated.
Constructor with
isMaster and one FileSplit settings. |
| Modifier and Type | Method and Description |
|---|---|
org.apache.hadoop.mapreduce.lib.input.FileSplit[] |
getFileSplits()
Deprecated.
|
long |
getLength()
Deprecated.
For master split, use
Long.MAX_VALUE as its length to make it is the first task for Hadoop job. |
String[] |
getLocations()
Deprecated.
Data locality functions, return all hosts for all file splits.
|
boolean |
isMaster()
Deprecated.
|
void |
readFields(DataInput in)
Deprecated.
|
void |
setFileSplits(org.apache.hadoop.mapreduce.lib.input.FileSplit[] fileSplits)
Deprecated.
|
void |
setMaster(boolean isMaster)
Deprecated.
|
String |
toString()
Deprecated.
|
void |
write(DataOutput out)
Deprecated.
|
public GuaguaInputSplit()
public GuaguaInputSplit(boolean isMaster,
org.apache.hadoop.mapreduce.lib.input.FileSplit... fileSplits)
isMaster and fileSplits settings.isMaster - Whether the input split is master split.fileSplits - File splits used for mapper task.public GuaguaInputSplit(boolean isMaster,
org.apache.hadoop.mapreduce.lib.input.FileSplit fileSplit)
isMaster and one FileSplit settings.isMaster - Whether the input split is master split.fileSplit - File split used for mapper task.public void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.WritableIOExceptionpublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.WritableIOExceptionpublic long getLength()
throws IOException,
InterruptedException
Long.MAX_VALUE as its length to make it is the first task for Hadoop job. It
is convenient for users to check master in Hadoop UI.getLength in class org.apache.hadoop.mapreduce.InputSplitIOExceptionInterruptedExceptionpublic String[] getLocations() throws IOException, InterruptedException
getLocations in class org.apache.hadoop.mapreduce.InputSplitIOExceptionInterruptedExceptionpublic boolean isMaster()
public void setMaster(boolean isMaster)
public org.apache.hadoop.mapreduce.lib.input.FileSplit[] getFileSplits()
public void setFileSplits(org.apache.hadoop.mapreduce.lib.input.FileSplit[] fileSplits)
Copyright © 2019. All Rights Reserved.