T - The type of engine-specific record representation, e.g.,InternalRow
in Spark and RowData in Flink.public final class HoodieFileGroupReader<T> extends Object implements Closeable
This should be used by the every engine integration, by plugging in a
HoodieReaderContext implementation.
| Modifier and Type | Class and Description |
|---|---|
static class |
HoodieFileGroupReader.HoodieFileGroupReaderIterator<T> |
| Constructor and Description |
|---|
HoodieFileGroupReader(HoodieReaderContext<T> readerContext,
HoodieStorage storage,
String tablePath,
String latestCommitTime,
FileSlice fileSlice,
org.apache.avro.Schema dataSchema,
org.apache.avro.Schema requestedSchema,
Option<InternalSchema> internalSchemaOpt,
HoodieTableMetaClient hoodieTableMetaClient,
TypedProperties props,
long start,
long length,
boolean shouldUseRecordPosition) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
HoodieFileGroupReader.HoodieFileGroupReaderIterator<T> |
getClosableIterator() |
static RecordMergeMode |
getRecordMergeMode(Properties props) |
boolean |
hasNext() |
void |
initRecordIterators()
Initialize internal iterators on the base and log files.
|
T |
next() |
public HoodieFileGroupReader(HoodieReaderContext<T> readerContext, HoodieStorage storage, String tablePath, String latestCommitTime, FileSlice fileSlice, org.apache.avro.Schema dataSchema, org.apache.avro.Schema requestedSchema, Option<InternalSchema> internalSchemaOpt, HoodieTableMetaClient hoodieTableMetaClient, TypedProperties props, long start, long length, boolean shouldUseRecordPosition)
public void initRecordIterators()
throws IOException
IOExceptionpublic boolean hasNext()
throws IOException
true if the next record exists; false otherwise.IOException - on reader error.public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionpublic HoodieFileGroupReader.HoodieFileGroupReaderIterator<T> getClosableIterator()
public static RecordMergeMode getRecordMergeMode(Properties props)
Copyright © 2024 The Apache Software Foundation. All rights reserved.