@InterfaceAudience.Public @InterfaceStability.Evolving public abstract class HCatReader extends Object
Modifier and Type | Field and Description |
---|---|
protected org.apache.hadoop.conf.Configuration |
conf |
protected ReaderContext |
info |
protected ReadEntity |
re |
protected StateProvider |
sp |
Modifier | Constructor and Description |
---|---|
protected |
HCatReader(org.apache.hadoop.conf.Configuration config,
StateProvider sp)
This constructor will be invoked by
DataTransferFactory at slave
nodes. |
protected |
HCatReader(ReadEntity re,
Map<String,String> config)
This constructor will be invoked by
DataTransferFactory at master
node. |
Modifier and Type | Method and Description |
---|---|
abstract ReaderContext |
prepareRead()
This should be called at master node to obtain
ReaderContext which
then should be serialized and sent to slave nodes. |
abstract Iterator<HCatRecord> |
read()
This should be called at slave nodes to read
HCatRecord s |
protected ReadEntity re
protected org.apache.hadoop.conf.Configuration conf
protected ReaderContext info
protected StateProvider sp
protected HCatReader(ReadEntity re, Map<String,String> config)
DataTransferFactory
at master
node. Don't use this constructor. Instead, use DataTransferFactory
re
- config
- protected HCatReader(org.apache.hadoop.conf.Configuration config, StateProvider sp)
DataTransferFactory
at slave
nodes. Don't use this constructor. Instead, use DataTransferFactory
config
- sp
- public abstract ReaderContext prepareRead() throws HCatException
ReaderContext
which
then should be serialized and sent to slave nodes.ReaderContext
HCatException
public abstract Iterator<HCatRecord> read() throws HCatException
HCatRecord
sIterator
of HCatRecord
HCatException
Copyright © 2017 The Apache Software Foundation. All rights reserved.