Class RegistryAvroDeserializationSchema<T>

    • Constructor Detail

      • RegistryAvroDeserializationSchema

        public RegistryAvroDeserializationSchema​(Class<T> recordClazz,
                                                 @Nullable
                                                 org.apache.avro.Schema reader,
                                                 SchemaCoder.SchemaCoderProvider schemaCoderProvider)
        Creates Avro deserialization schema that reads schema from input stream using provided SchemaCoder.
        Parameters:
        recordClazz - class to which deserialize. Should be either SpecificRecord or GenericRecord.
        reader - reader's Avro schema. Should be provided if recordClazz is GenericRecord
        schemaCoderProvider - schema provider that allows instantiation of SchemaCoder that will be used for schema reading
      • RegistryAvroDeserializationSchema

        public RegistryAvroDeserializationSchema​(Class<T> recordClazz,
                                                 @Nullable
                                                 org.apache.avro.Schema reader,
                                                 SchemaCoder.SchemaCoderProvider schemaCoderProvider,
                                                 AvroFormatOptions.AvroEncoding encoding)
        Creates Avro deserialization schema that reads schema from input stream using provided SchemaCoder.
        Parameters:
        recordClazz - class to which deserialize. Should be either SpecificRecord or GenericRecord.
        reader - reader's Avro schema. Should be provided if recordClazz is GenericRecord
        schemaCoderProvider - schema provider that allows instantiation of SchemaCoder that will be used for schema reading
        encoding - Avro serialization approach to use. Required to identify the correct decoder class to use.