Documentation
¶
Index ¶
- Constants
- func AppendPKIndexSuffix(dataPath string) string
- func AppendSecondaryIndexSuffix(dataPath string, fieldName string, indexType index.IndexType, fileType int) string
- func InitDecFunctions()
- func MarshalPkMetaBlock(startId, endId uint64, offset, size uint32, meta, colsOffset []byte) []byte
- type ChunkBuilder
- type ColumnBuilder
- type DetachedPKData
- type DetachedPKInfo
- type DetachedPKMeta
- type DetachedPKMetaInfo
- type IndexBuilder
- func (b *IndexBuilder) GetEncodeChunkSize() uint32
- func (b *IndexBuilder) Reset()
- func (b *IndexBuilder) WriteData(rec *record.Record, tcLocation int8) error
- func (b *IndexBuilder) WriteDetachedData(rec *record.Record, tcLocation int8) error
- func (b *IndexBuilder) WriteDetachedMeta(startId, endId uint64, offset, size uint32, fd fileops.File) error
- type IndexWriter
- type PKFiles
- type PKInfo
- type PKInfos
- type PkMetaBlock
- type PrimaryKeyReader
- func (r *PrimaryKeyReader) Close() error
- func (r *PrimaryKeyReader) FileSize() int64
- func (r *PrimaryKeyReader) Open() error
- func (r *PrimaryKeyReader) Read(offset int64, size uint32, dst *[]byte) ([]byte, error)
- func (r *PrimaryKeyReader) ReadData() (*record.Record, int8, error)
- func (r *PrimaryKeyReader) Version() uint32
Constants ¶
View Source
const ( PKMetaPrefixSize = util.Uint64SizeBytes*2 + util.Uint32SizeBytes*2 CRCLen = 4 )
View Source
const ( CoarseIndexFragment int = 8 MinRowsForSeek int = 0 IndexFileSuffix string = ".idx" MinMaxIndexFileSuffix string = ".mm" SetIndexFileSuffix string = ".set" BloomFilterIndexFileSuffix string = ".bf" TextIndexDataFileSuffix string = ".pos" // posting list TextIndexHeadFileSuffix string = ".bh" // block header TextIndexPartFileSuffix string = ".ph" // part header DefaultTCLocation int8 = -1 )
View Source
const ( TextIndexData = iota TextIndexHead TextIndexPart TextIndexMax )
Variables ¶
This section is empty.
Functions ¶
func AppendPKIndexSuffix ¶ added in v1.2.0
func AppendSecondaryIndexSuffix ¶ added in v1.3.0
func InitDecFunctions ¶
func InitDecFunctions()
Types ¶
type ChunkBuilder ¶
type ChunkBuilder struct {
// contains filtered or unexported fields
}
func NewChunkBuilder ¶
func NewChunkBuilder() *ChunkBuilder
func (*ChunkBuilder) EncodeChunk ¶
type ColumnBuilder ¶
type ColumnBuilder struct {
// contains filtered or unexported fields
}
func NewColumnBuilder ¶
func NewColumnBuilder() *ColumnBuilder
func (*ColumnBuilder) EncodeColumn ¶
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
func (*DetachedPKInfo) GetEndBlockId ¶ added in v1.3.0
func (d *DetachedPKInfo) GetEndBlockId() uint64
func (*DetachedPKInfo) GetStartBlockId ¶ added in v1.3.0
func (d *DetachedPKInfo) GetStartBlockId() uint64
func (*DetachedPKInfo) IsBlockExist ¶ added in v1.3.0
func (d *DetachedPKInfo) IsBlockExist(start, end uint64) bool
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
type DetachedPKMetaInfo ¶ added in v1.2.0
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
type IndexWriter ¶ added in v1.3.0
type IndexWriter struct {
// contains filtered or unexported fields
}
func NewIndexWriter ¶ added in v1.3.0
func NewIndexWriter(lockPath *string, filePath string) (*IndexWriter, error)
func (*IndexWriter) Reset ¶ added in v1.3.0
func (b *IndexWriter) Reset()
func (*IndexWriter) WriteData ¶ added in v1.3.0
func (b *IndexWriter) WriteData(data []byte) error
type PKFiles ¶
type PKFiles struct {
// contains filtered or unexported fields
}
func NewPKFiles ¶
func NewPKFiles() *PKFiles
func (*PKFiles) GetPKInfos ¶
type PKInfo ¶
type PKInfo struct {
// contains filtered or unexported fields
}
func (*PKInfo) GetMark ¶
func (p *PKInfo) GetMark() fragment.IndexFragment
func (*PKInfo) GetTCLocation ¶ added in v1.1.1
type PkMetaBlock ¶ added in v1.3.0
func UnmarshalPkMetaBlock ¶ added in v1.3.0
func UnmarshalPkMetaBlock(src []byte) (*PkMetaBlock, error)
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) ReadData ¶
func (r *PrimaryKeyReader) ReadData() (*record.Record, int8, error)
func (*PrimaryKeyReader) Version ¶
func (r *PrimaryKeyReader) Version() uint32
Click to show internal directories.
Click to hide internal directories.