@NotThreadSafe public class HoodieAvroParquetWriter<R extends org.apache.avro.generic.IndexedRecord> extends HoodieBaseParquetWriter<org.apache.avro.generic.IndexedRecord> implements HoodieFileWriter<R>
canWrite()
ATTENTION: HoodieParquetWriter is not thread safe and developer should take care of the order of write and close| Constructor and Description |
|---|
HoodieAvroParquetWriter(org.apache.hadoop.fs.Path file,
HoodieParquetConfig<HoodieAvroWriteSupport> parquetConfig,
String instantTime,
TaskContextSupplier taskContextSupplier,
boolean populateMetaFields) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
writeAvro(String key,
org.apache.avro.generic.IndexedRecord object) |
void |
writeAvroWithMetadata(HoodieKey key,
R avroRecord) |
canWrite, getWrittenRecordCount, writeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcanWrite, prepRecordWithMetadatapublic HoodieAvroParquetWriter(org.apache.hadoop.fs.Path file,
HoodieParquetConfig<HoodieAvroWriteSupport> parquetConfig,
String instantTime,
TaskContextSupplier taskContextSupplier,
boolean populateMetaFields)
throws IOException
IOExceptionpublic void writeAvroWithMetadata(HoodieKey key, R avroRecord) throws IOException
writeAvroWithMetadata in interface HoodieFileWriter<R extends org.apache.avro.generic.IndexedRecord>IOExceptionpublic void writeAvro(String key, org.apache.avro.generic.IndexedRecord object) throws IOException
writeAvro in interface HoodieFileWriter<R extends org.apache.avro.generic.IndexedRecord>IOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in interface HoodieFileWriter<R extends org.apache.avro.generic.IndexedRecord>close in class org.apache.parquet.hadoop.ParquetWriter<org.apache.avro.generic.IndexedRecord>IOExceptionCopyright © 2022 The Apache Software Foundation. All rights reserved.