Table of Contents

Class AvroFileReaderOptions

Namespace
AvroSharp.Containers
Assembly
AvroSharp.dll

Options for AvroFileReader<T>.

public sealed class AvroFileReaderOptions
Inheritance
AvroFileReaderOptions
Inherited Members

Fields

DefaultMaxBlockLength

The default MaxBlockLength: 64 MiB.

DefaultMaxSchemaLength

The default MaxSchemaLength: 4 MiB.

DefaultMaxZeroSizeValuesPerBlock

The default MaxZeroSizeValuesPerBlock: 16,777,216.

Properties

Codecs

Gets the codecs available besides the built-in null and deflate codecs, matched by Name against the file's avro.codec entry. A codec added here replaces a built-in one of the same name.

Default

Gets the default options.

LeaveOpen

Gets whether disposing the reader leaves the stream open. The default is false.

MaxBlockLength

Gets the largest block, compressed or decompressed, and the largest header metadata value, in bytes. It bounds the memory a file can make the reader allocate. The default is DefaultMaxBlockLength.

MaxSchemaLength

Gets the largest avro.schema header entry, in bytes. Parsing a schema allocates about 20 times its JSON, so this bounds what a file's header can make the reader allocate, below MaxBlockLength. The default is DefaultMaxSchemaLength.

MaxZeroSizeValuesPerBlock

Gets how many zero-size values a block may declare, when the file's schema lets an object encode to no bytes (null, or records of such fields). The input cannot bound those objects, so a few bytes could declare any number of them. Each object counts as the values reading it creates: one, plus one per field of each record in it. The default is DefaultMaxZeroSizeValuesPerBlock; AvroFileWriter<T> writes at most 65,536 objects per block.

See Also