metautil

package
v0.0.0-...-572c485 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildDeltaLogPath

func BuildDeltaLogPath(rootPath string, collectionID, partitionID, segmentID, logID typeutil.UniqueID) string

func BuildInsertLogPath

func BuildInsertLogPath(rootPath string, collectionID, partitionID, segmentID, fieldID, logID typeutil.UniqueID) string

func BuildSegmentIndexFilePath

func BuildSegmentIndexFilePath(rootPath string, buildID, indexVersion, partID, segID int64, fileKey string) string

func BuildSegmentIndexFilePaths

func BuildSegmentIndexFilePaths(rootPath string, buildID, indexVersion, partID, segID int64, fileKeys []string) []string

func BuildStatsLogPath

func BuildStatsLogPath(rootPath string, collectionID, partitionID, segmentID, fieldID, logID typeutil.UniqueID) string

func GetSegmentIDFromDeltaLogPath

func GetSegmentIDFromDeltaLogPath(logPath string) typeutil.UniqueID

func GetSegmentIDFromInsertLogPath

func GetSegmentIDFromInsertLogPath(logPath string) typeutil.UniqueID

func GetSegmentIDFromStatsLogPath

func GetSegmentIDFromStatsLogPath(logPath string) typeutil.UniqueID

func JoinIDPath

func JoinIDPath(ids ...typeutil.UniqueID) string

JoinIDPath joins ids to path format.

func NewDynChannelMapper

func NewDynChannelMapper() *dynamicChannelMapper

func ParseInsertLogPath

func ParseInsertLogPath(path string) (collectionID, partitionID, segmentID, fieldID, logID typeutil.UniqueID, ok bool)

Types

type Channel

type Channel struct {
	ChannelMapper
	// contains filtered or unexported fields
}

Channel struct maintains the channel information

func NewChannel

func NewChannel(physicalName string, collectionID int64, idx int64, mapper ChannelMapper) Channel

NewChannel returns a Channel instance with provided physical channel and other informations.

func ParseChannel

func ParseChannel(virtualName string, mapper ChannelMapper) (Channel, error)

func (Channel) Equal

func (c Channel) Equal(ac Channel) bool

func (Channel) EqualString

func (c Channel) EqualString(str string) bool

func (Channel) PhysicalName

func (c Channel) PhysicalName() string

func (Channel) VirtualName

func (c Channel) VirtualName() string

type ChannelMapper

type ChannelMapper interface {
	ChannelIdx(string) int
	ChannelName(int) string
}

ChannelMapper is the interface provides physical channel name mapping functions.

Jump to

Keyboard shortcuts

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