options.go
options.go - Overview
This file defines types and constants related to checksum verification modes and compression types used in the database.
Detailed Documentation
Type: ChecksumVerificationMode
type ChecksumVerificationMode int
Purpose: Defines the different modes for verifying checksums of SSTable blocks.
Constants:
NoVerification
:
const (
// NoVerification indicates DB should not verify checksum for SSTable blocks.
NoVerification ChecksumVerificationMode = iota
Purpose: Specifies that the database should not verify checksums for SSTable blocks.
OnTableRead
:
// OnTableRead indicates checksum should be verified while opening SSTtable.
OnTableRead
Purpose: Specifies that checksums should be verified when opening an SSTable.
OnBlockRead
:
// OnBlockRead indicates checksum should be verified on every SSTable block read.
OnBlockRead
Purpose: Specifies that checksums should be verified on every SSTable block read.
OnTableAndBlockRead
:
// OnTableAndBlockRead indicates checksum should be verified
// on SSTable opening and on every block read.
OnTableAndBlockRead
Purpose: Specifies that checksums should be verified both when opening an SSTable and on every block read.
Type: CompressionType
type CompressionType uint32
Purpose: Defines the different compression algorithms that can be used for blocks.
Constants:
None
:
const (
// None mode indicates that a block is not compressed.
None CompressionType = 0
Purpose: Specifies that a block is not compressed.
Snappy
:
// Snappy mode indicates that a block is compressed using Snappy algorithm.
Snappy CompressionType = 1
Purpose: Specifies that a block is compressed using the Snappy algorithm.
ZSTD
:
// ZSTD mode indicates that a block is compressed using ZSTD algorithm.
ZSTD CompressionType = 2
)
Purpose: Specifies that a block is compressed using the ZSTD algorithm.