colstore

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RowsNumPerFragment         int    = util.RowsNumPerFragment
	CoarseIndexFragment        int    = 8
	MinRowsForSeek             int    = 0
	IndexFileSuffix            string = ".idx"
	MinMaxIndexFileSuffix      string = ".mm"
	SetIndexFileSuffix         string = ".set"
	BloomFilterIndexFileSuffix string = ".bf"
	DefaultTCLocation          int8   = -1
)

Variables

This section is empty.

Functions

func AppendPKIndexSuffix added in v1.2.0

func AppendPKIndexSuffix(dataPath string) string

func AppendSKIndexSuffix added in v1.2.0

func AppendSKIndexSuffix(dataPath string, fieldName string, indexName string) string

func InitDecFunctions

func InitDecFunctions()

Types

type ChunkBuilder

type ChunkBuilder struct {
	// contains filtered or unexported fields
}

func NewChunkBuilder

func NewChunkBuilder() *ChunkBuilder

func (*ChunkBuilder) EncodeChunk

func (b *ChunkBuilder) EncodeChunk(rec *record.Record, dst []byte, offset []byte, offsetStart uint32) ([]byte, error)

type ColumnBuilder

type ColumnBuilder struct {
	// contains filtered or unexported fields
}

func NewColumnBuilder

func NewColumnBuilder() *ColumnBuilder

func (*ColumnBuilder) EncodeColumn

func (b *ColumnBuilder) EncodeColumn(ref *record.Field, col *record.ColVal) ([]byte, error)

type DetachedPKData added in v1.2.0

type DetachedPKData struct {
	Offset int64 // temporary variable, used for sorting
	Data   *record.Record
}

func (*DetachedPKData) Unmarshal added in v1.2.0

func (m *DetachedPKData) Unmarshal(src []byte, meta *DetachedPKMeta, info *DetachedPKMetaInfo) ([]byte, error)

type DetachedPKInfo added in v1.2.0

type DetachedPKInfo struct {
	StartBlockId uint64
	EndBlockId   uint64
	TcLocation   int8
	Data         *record.Record
}

func GetPKInfoByPKMetaData added in v1.2.0

func GetPKInfoByPKMetaData(meta *DetachedPKMeta, data *DetachedPKData, tcLocation int8) *DetachedPKInfo

type DetachedPKMeta added in v1.2.0

type DetachedPKMeta struct {
	StartBlockId uint64
	EndBlockId   uint64
	Offset       uint32
	Length       uint32
	ColOffset    []byte
}

func (*DetachedPKMeta) Size added in v1.2.0

func (m *DetachedPKMeta) Size() int

func (*DetachedPKMeta) Unmarshal added in v1.2.0

func (m *DetachedPKMeta) Unmarshal(src []byte) ([]byte, error)

type DetachedPKMetaInfo added in v1.2.0

type DetachedPKMetaInfo struct {
	Schema     record.Schemas
	TCLocation int8
	Offset     int64
}

func (*DetachedPKMetaInfo) Size added in v1.2.0

func (m *DetachedPKMetaInfo) Size() int

func (*DetachedPKMetaInfo) Unmarshal added in v1.2.0

func (m *DetachedPKMetaInfo) Unmarshal(src []byte) ([]byte, error)

func (*DetachedPKMetaInfo) UnmarshalPublicSize added in v1.2.0

func (m *DetachedPKMetaInfo) UnmarshalPublicSize(src []byte) ([]byte, error)

type IndexBuilder

type IndexBuilder struct {
	// contains filtered or unexported fields
}

func NewIndexBuilder

func NewIndexBuilder(lockPath *string, filePath string) *IndexBuilder

func NewIndexBuilderByFd added in v1.2.0

func NewIndexBuilderByFd(lockPath *string, fd fileops.File, firstFlush bool) *IndexBuilder

func (*IndexBuilder) GetEncodeChunkSize added in v1.2.0

func (b *IndexBuilder) GetEncodeChunkSize() uint32

func (*IndexBuilder) Reset

func (b *IndexBuilder) Reset()

func (*IndexBuilder) WriteData

func (b *IndexBuilder) WriteData(rec *record.Record, tcLocation int8) error

func (*IndexBuilder) WriteDetachedData added in v1.2.0

func (b *IndexBuilder) WriteDetachedData(rec *record.Record, tcLocation int8) error

func (*IndexBuilder) WriteDetachedMeta added in v1.2.0

func (b *IndexBuilder) WriteDetachedMeta(startId, endId uint64, offset, size uint32, fd fileops.File) error

type PKFiles

type PKFiles struct {
	// contains filtered or unexported fields
}

func NewPKFiles

func NewPKFiles() *PKFiles

func (*PKFiles) DelPKInfo

func (f *PKFiles) DelPKInfo(file string)

func (*PKFiles) GetPKInfo

func (f *PKFiles) GetPKInfo(file string) (*PKInfo, bool)

func (*PKFiles) GetPKInfos

func (f *PKFiles) GetPKInfos() PKInfos

func (*PKFiles) SetPKInfo

func (f *PKFiles) SetPKInfo(file string, rec *record.Record, mark fragment.IndexFragment, tcLocation int8)

type PKInfo

type PKInfo struct {
	// contains filtered or unexported fields
}

func (*PKInfo) GetMark

func (p *PKInfo) GetMark() fragment.IndexFragment

func (*PKInfo) GetRec

func (p *PKInfo) GetRec() *record.Record

func (*PKInfo) GetTCLocation added in v1.1.1

func (p *PKInfo) GetTCLocation() int8

type PKInfos

type PKInfos map[string]*PKInfo

type PrimaryKeyReader

type PrimaryKeyReader struct {
	// contains filtered or unexported fields
}

func NewPrimaryKeyReader

func NewPrimaryKeyReader(name string, lockPath *string) (*PrimaryKeyReader, error)

func (*PrimaryKeyReader) Close

func (r *PrimaryKeyReader) Close() error

func (*PrimaryKeyReader) FileSize

func (r *PrimaryKeyReader) FileSize() int64

func (*PrimaryKeyReader) Open

func (r *PrimaryKeyReader) Open() error

func (*PrimaryKeyReader) Read

func (r *PrimaryKeyReader) Read(offset int64, size uint32, dst *[]byte) ([]byte, error)

func (*PrimaryKeyReader) ReadData

func (r *PrimaryKeyReader) ReadData() (*record.Record, int8, error)

func (*PrimaryKeyReader) Version

func (r *PrimaryKeyReader) Version() uint32

type SkipIndexBuilder added in v1.2.0

type SkipIndexBuilder struct {
	// contains filtered or unexported fields
}

func NewSkipIndexBuilder added in v1.2.0

func NewSkipIndexBuilder(lockPath *string, filePath string) *SkipIndexBuilder

func (*SkipIndexBuilder) Reset added in v1.2.0

func (b *SkipIndexBuilder) Reset()

func (*SkipIndexBuilder) WriteData added in v1.2.0

func (b *SkipIndexBuilder) WriteData(data []byte) error

Jump to

Keyboard shortcuts

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