T
- The type of element to write.@PublicEvolving public class OrcBulkWriterFactory<T> extends Object implements BulkWriter.Factory<T>
BulkWriter
. The factory takes a user supplied Vectorizer
implementation to convert the element into an VectorizedRowBatch
.Constructor and Description |
---|
OrcBulkWriterFactory(Vectorizer<T> vectorizer)
Creates a new OrcBulkWriterFactory using the provided Vectorizer implementation.
|
OrcBulkWriterFactory(Vectorizer<T> vectorizer,
Configuration configuration)
Creates a new OrcBulkWriterFactory using the provided Vectorizer, Hadoop Configuration.
|
OrcBulkWriterFactory(Vectorizer<T> vectorizer,
Properties writerProperties,
Configuration configuration)
Creates a new OrcBulkWriterFactory using the provided Vectorizer, Hadoop Configuration, ORC
writer properties.
|
Modifier and Type | Method and Description |
---|---|
BulkWriter<T> |
create(FSDataOutputStream out)
Creates a writer that writes to the given stream.
|
protected org.apache.orc.OrcFile.WriterOptions |
getWriterOptions() |
public OrcBulkWriterFactory(Vectorizer<T> vectorizer)
vectorizer
- The vectorizer implementation to convert input record to a
VectorizerRowBatch.public OrcBulkWriterFactory(Vectorizer<T> vectorizer, Configuration configuration)
vectorizer
- The vectorizer implementation to convert input record to a
VectorizerRowBatch.public OrcBulkWriterFactory(Vectorizer<T> vectorizer, Properties writerProperties, Configuration configuration)
vectorizer
- The vectorizer implementation to convert input record to a
VectorizerRowBatch.writerProperties
- Properties that can be used in ORC WriterOptions.public BulkWriter<T> create(FSDataOutputStream out) throws IOException
BulkWriter.Factory
create
in interface BulkWriter.Factory<T>
out
- The output stream to write the encoded data to.IOException
- Thrown if the writer cannot be opened, or if the output stream throws
an exception.@VisibleForTesting protected org.apache.orc.OrcFile.WriterOptions getWriterOptions()
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.