Class AvroWriteSupport<T>


  • public class AvroWriteSupport<T>
    extends org.apache.parquet.hadoop.api.WriteSupport<T>
    Avro implementation of WriteSupport for generic, specific, and reflect models. Use AvroParquetWriter or AvroParquetOutputFormat rather than using this class directly.
    • Constructor Detail

      • AvroWriteSupport

        public AvroWriteSupport()
      • AvroWriteSupport

        @Deprecated
        public AvroWriteSupport​(org.apache.parquet.schema.MessageType schema,
                                org.apache.avro.Schema avroSchema)
        Deprecated.
        will be removed in 2.0.0
        Parameters:
        schema - the write parquet schema
        avroSchema - the write avro schema
      • AvroWriteSupport

        public AvroWriteSupport​(org.apache.parquet.schema.MessageType schema,
                                org.apache.avro.Schema avroSchema,
                                org.apache.avro.generic.GenericData model)
    • Method Detail

      • setAvroDataSupplier

        public static void setAvroDataSupplier​(org.apache.hadoop.conf.Configuration configuration,
                                               Class<? extends AvroDataSupplier> suppClass)
      • getName

        public String getName()
        Overrides:
        getName in class org.apache.parquet.hadoop.api.WriteSupport<T>
      • init

        public org.apache.parquet.hadoop.api.WriteSupport.WriteContext init​(org.apache.hadoop.conf.Configuration configuration)
        Specified by:
        init in class org.apache.parquet.hadoop.api.WriteSupport<T>
      • prepareForWrite

        public void prepareForWrite​(org.apache.parquet.io.api.RecordConsumer recordConsumer)
        Specified by:
        prepareForWrite in class org.apache.parquet.hadoop.api.WriteSupport<T>
      • write

        public void write​(org.apache.avro.generic.IndexedRecord record)
      • write

        public void write​(T record)
        Specified by:
        write in class org.apache.parquet.hadoop.api.WriteSupport<T>