|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hadoop.tools.mapred.lib.DynamicInputChunkSet
public class DynamicInputChunkSet
The DynamicInputChunkSet abstracts the context in which a DynamicInputChunk is constructed, acquired or released. There is one instance of DynamicInputChunkSet for each unique Hadoop job that uses the DynamicInputFormat.
| Constructor Summary | |
|---|---|
DynamicInputChunkSet(org.apache.hadoop.conf.Configuration configuration)
Constructor, to initialize the context in which DynamicInputChunks are used. |
|
| Method Summary | |
|---|---|
org.apache.hadoop.tools.mapred.lib.DynamicInputChunk |
acquire(org.apache.hadoop.mapreduce.TaskAttemptContext taskAttemptContext)
Factory method that 1. |
org.apache.hadoop.tools.mapred.lib.DynamicInputChunk |
createChunkForWrite(String chunkId)
Factory method to create chunk-files for writing to. |
String |
getChunkFilePrefix()
The string with which all chunk-file-names are prefixed. |
org.apache.hadoop.fs.Path |
getChunkRootPath()
The root-path of the directory where DynamicInputChunks are stored. |
org.apache.hadoop.conf.Configuration |
getConf()
Getter for the Configuration with which the DynamicInputChunkSet was constructed. |
org.apache.hadoop.fs.FileSystem |
getFileSystem()
FileSystem instance, for the file-system where the chunk-files are stored. |
int |
getNumChunksLeft()
Number of chunk-files left, on last directory scan. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DynamicInputChunkSet(org.apache.hadoop.conf.Configuration configuration)
throws IOException
configuration - The Configuration instance, as received from the
DynamicInputFormat or DynamicRecordReader.
IOException - Exception in case of failure.| Method Detail |
|---|
public org.apache.hadoop.conf.Configuration getConf()
public org.apache.hadoop.fs.Path getChunkRootPath()
public String getChunkFilePrefix()
public int getNumChunksLeft()
public org.apache.hadoop.fs.FileSystem getFileSystem()
public org.apache.hadoop.tools.mapred.lib.DynamicInputChunk createChunkForWrite(String chunkId)
throws IOException
chunkId - String to identify the chunk.
IOException - Exception on failure to create the chunk.
public org.apache.hadoop.tools.mapred.lib.DynamicInputChunk acquire(org.apache.hadoop.mapreduce.TaskAttemptContext taskAttemptContext)
throws IOException,
InterruptedException
taskAttemptContext - The attempt-context for the map task that's
trying to acquire a chunk.
IOException - Exception on failure.
InterruptedException - Exception on failure.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||