Documentation ¶
Index ¶
Constants ¶
const MajorVersion = 1
MajorVersion is the major schema version for a set of fileset files, this is only incremented when breaking changes are introduced and tooling needs to upgrade older files to newer files before a server restart
const MinorVersion = 1
MinorVersion is the minor schema version for a set of fileset files. This is only incremented when *non-breaking* changes are introduced that we want to have some level of control around how they're rolled out.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IndexBloomFilterInfo ¶
IndexBloomFilterInfo stores metadata about the bloom filter.
type IndexChecksum ¶ added in v1.0.0
type IndexChecksum struct { // IndexChecksum embeds IndexEntry. IndexEntry // MetadataChecksum is the computed index metadata checksum. // NB: built from ID, DataChecksum, and tags. MetadataChecksum int64 }
IndexChecksum extends IndexEntry for use with queries, by providing an additional metadata checksum field.
type IndexEntry ¶
type IndexEntry struct { Index int64 ID []byte Size int64 Offset int64 DataChecksum int64 EncodedTags []byte IndexChecksum int64 }
IndexEntry stores entry-level data indexing.
When serialized to disk, the encoder will automatically add the IndexEntryChecksum, a checksum to validate the index entry itself, to the end of the entry. That field is not exposed on this struct as this is handled transparently by the encoder and decoder. Appending of checksum starts in V3.
type IndexEntryHasher ¶ added in v1.0.0
type IndexEntryHasher interface { // HashIndexEntry computes a hash value for this IndexEntry using its ID, tags, // and the computed data checksum. HashIndexEntry(e IndexEntry) int64 }
IndexEntryHasher hashes an index entry.
func NewXXHasher ¶ added in v1.0.0
func NewXXHasher() IndexEntryHasher
NewXXHasher returns an IndexEntryHasher utilizing xxHash hashing.
type IndexInfo ¶
type IndexInfo struct { MajorVersion int64 BlockStart int64 BlockSize int64 Entries int64 Summaries IndexSummariesInfo BloomFilter IndexBloomFilterInfo SnapshotTime int64 FileType persist.FileSetType SnapshotID []byte VolumeIndex int MinorVersion int64 }
IndexInfo stores metadata information about block filesets.
type IndexSummariesInfo ¶
type IndexSummariesInfo struct {
Summaries int64
}
IndexSummariesInfo stores metadata about the summaries.
type IndexSummary ¶
IndexSummary stores a summary of an index entry to lookup.
type LogEntry ¶
type LogEntry struct { Index uint64 Create int64 Metadata []byte Timestamp int64 Value float64 Unit uint32 Annotation []byte }
LogEntry stores per-entry data in a commit log
type LogInfo ¶
type LogInfo struct { // Deprecated fields, left intact as documentation for the actual // format on disk. DeprecatedDoNotUseStart int64 DeprecatedDoNotUseDuration int64 Index int64 }
LogInfo stores summary information about a commit log.
type LogMetadata ¶
LogMetadata stores metadata information about a commit log.
type VersionChecker ¶ added in v0.15.7
type VersionChecker struct {
// contains filtered or unexported fields
}
VersionChecker centralizes logic for checking if a major, minor version combo supports specific functionality
func NewVersionChecker ¶ added in v0.15.7
func NewVersionChecker(majorVersion int, minorVersion int) VersionChecker
NewVersionChecker creates a new VersionChecker
func (*VersionChecker) IndexEntryValidationEnabled ¶ added in v0.15.7
func (v *VersionChecker) IndexEntryValidationEnabled() bool
IndexEntryValidationEnabled checks the version to determine if fileset files of the specified version allow for doing checksum validation on individual index entries