config

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 6, 2023 License: Apache-2.0 Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Pool memory.Allocator

	// InitIndexSize sets the initial size of a dictionary index.
	InitIndexSize uint64
	// LimitIndexSize sets the maximum size of a dictionary index
	// before it is no longer encoded as a dictionary.
	LimitIndexSize uint64
	// Zstd enables the use of ZSTD compression for IPC messages.
	Zstd bool // Use IPC ZSTD compression
	// Stats enables the collection of statistics about the data being encoded.
	Stats bool
}

func DefaultConfig

func DefaultConfig() *Config

DefaultConfig returns a Config with the following default values:

  • Pool: memory.NewGoAllocator()
  • InitIndexSize: math.MaxUint16
  • LimitIndexSize: math.MaxUint32
  • Stats: false
  • Zstd: true

type Option

type Option func(*Config)

func WithAllocator

func WithAllocator(allocator memory.Allocator) Option

WithAllocator sets the allocator to use for the Producer.

func WithNoDictionary

func WithNoDictionary() Option

WithNoDictionary sets the Producer to not use dictionary encoding.

func WithNoZstd

func WithNoZstd() Option

WithNoZstd sets the Producer to not use Zstd compression at the Arrow IPC level.

func WithStats

func WithStats() Option

WithStats enables the collection of statistics about the data being encoded.

func WithUint16InitDictIndex

func WithUint16InitDictIndex() Option

WithUint16InitDictIndex sets the Producer to use an uint16 index for all dictionaries.

func WithUint16LimitDictIndex

func WithUint16LimitDictIndex() Option

WithUint16LimitDictIndex sets the Producer to fall back to non dictionary encoding if the dictionary size exceeds an uint16 index.

func WithUint32LimitDictIndex

func WithUint32LimitDictIndex() Option

WithUint32LimitDictIndex sets the Producer to fall back to non dictionary encoding if the dictionary size exceeds an uint32 index.

func WithUint32LinitDictIndex

func WithUint32LinitDictIndex() Option

WithUint32LinitDictIndex sets the Producer to use an uint32 index for all dictionaries.

func WithUint64InitDictIndex

func WithUint64InitDictIndex() Option

WithUint64InitDictIndex sets the Producer to use an uint64 index for all dictionaries.

func WithUint64LimitDictIndex

func WithUint64LimitDictIndex() Option

WithUint64LimitDictIndex sets the Producer to fall back to non dictionary encoding if the dictionary size exceeds an uint64 index.

func WithUint8InitDictIndex

func WithUint8InitDictIndex() Option

WithUint8InitDictIndex sets the Producer to use an uint8 index for all dictionaries.

func WithUint8LimitDictIndex

func WithUint8LimitDictIndex() Option

WithUint8LimitDictIndex sets the Producer to fall back to non dictionary encoding if the dictionary size exceeds an uint8 index.

func WithZstd

func WithZstd() Option

WithZstd sets the Producer to use Zstd compression at the Arrow IPC level.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL