public class TableStoreRecordReader extends Object implements org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
RecordReader
for table store. Reads KeyValue
s from data files and picks out
RowData
for Hive to consume.
NOTE: To support projection push down, when selectedColumns
does not match columnNames
this reader will still produce records of the original schema. However, columns not
in selectedColumns
will be null.
Constructor and Description |
---|
TableStoreRecordReader(TableRead read,
TableStoreInputSplit split,
List<String> columnNames,
List<String> selectedColumns) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
Void |
createKey() |
RowDataContainer |
createValue() |
long |
getPos() |
float |
getProgress() |
boolean |
next(Void key,
RowDataContainer value) |
public TableStoreRecordReader(TableRead read, TableStoreInputSplit split, List<String> columnNames, List<String> selectedColumns) throws IOException
IOException
public boolean next(Void key, RowDataContainer value) throws IOException
next
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
IOException
public Void createKey()
createKey
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
public RowDataContainer createValue()
createValue
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
public long getPos() throws IOException
getPos
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
IOException
public float getProgress() throws IOException
getProgress
in interface org.apache.hadoop.mapred.RecordReader<Void,RowDataContainer>
IOException
Copyright © 2019–2023 The Apache Software Foundation. All rights reserved.