Documentation ¶
Index ¶
- Constants
- func BuildBootstrapIndexSegment(ns namespace.Metadata, requestedRanges result.ShardTimeRanges, ...) (result.IndexBlock, error)
- func EnqueueReaders(opts EnqueueReadersOptions)
- func GetDefaultIndexBlockForBlockStart(results result.IndexResults, blockStart xtime.UnixNano) (result.IndexBlock, bool)
- func NewBaseBootstrapper(name string, src bootstrap.Source, opts result.Options, ...) (bootstrap.Bootstrapper, error)
- func NewNoOpAllBootstrapperProvider() bootstrap.BootstrapperProvider
- func NewNoOpNoneBootstrapperProvider() bootstrap.BootstrapperProvider
- func PersistBootstrapIndexSegment(ns namespace.Metadata, requestedRanges result.ShardTimeRanges, ...) (result.IndexBlock, error)
- type EnqueueReadersOptions
- type NewReaderPoolOptions
- type ReaderPool
- type ReaderPoolAllocFn
- type ShardID
- type ShardReaders
- type ShardTimeRangesTimeWindowGroup
- type SharedCompactor
- type SharedPersistManager
- type TimeWindowReaders
Constants ¶
const ( // NoOpNoneBootstrapperName is the name of the noOpNoneBootstrapper NoOpNoneBootstrapperName = "noop-none" // NoOpAllBootstrapperName is the name of the noOpAllBootstrapperProvider NoOpAllBootstrapperName = "noop-all" )
Variables ¶
This section is empty.
Functions ¶
func BuildBootstrapIndexSegment ¶ added in v0.15.0
func BuildBootstrapIndexSegment( ns namespace.Metadata, requestedRanges result.ShardTimeRanges, builder segment.DocumentsBuilder, compactor *SharedCompactor, resultOpts result.Options, mmapReporter mmap.Reporter, blockStart xtime.UnixNano, blockEnd xtime.UnixNano, ) (result.IndexBlock, error)
BuildBootstrapIndexSegment is a helper function that builds (in memory) bootstrapped index segments for a ns -> block of time.
func EnqueueReaders ¶ added in v0.15.0
func EnqueueReaders(opts EnqueueReadersOptions)
EnqueueReaders into a readers channel grouped by data block.
func GetDefaultIndexBlockForBlockStart ¶ added in v0.15.0
func GetDefaultIndexBlockForBlockStart( results result.IndexResults, blockStart xtime.UnixNano, ) (result.IndexBlock, bool)
GetDefaultIndexBlockForBlockStart gets the index block for the default volume type from the index results.
func NewBaseBootstrapper ¶
func NewBaseBootstrapper( name string, src bootstrap.Source, opts result.Options, next bootstrap.Bootstrapper, ) (bootstrap.Bootstrapper, error)
NewBaseBootstrapper creates a new base bootstrapper.
func NewNoOpAllBootstrapperProvider ¶
func NewNoOpAllBootstrapperProvider() bootstrap.BootstrapperProvider
NewNoOpAllBootstrapperProvider creates a new noOpAllBootstrapperProvider.
func NewNoOpNoneBootstrapperProvider ¶
func NewNoOpNoneBootstrapperProvider() bootstrap.BootstrapperProvider
NewNoOpNoneBootstrapperProvider creates a new noOpNoneBootstrapper.
func PersistBootstrapIndexSegment ¶ added in v0.15.0
func PersistBootstrapIndexSegment( ns namespace.Metadata, requestedRanges result.ShardTimeRanges, builder segment.DocumentsBuilder, persistManager *SharedPersistManager, indexClaimsManager fs.IndexClaimsManager, resultOpts result.Options, fulfilled result.ShardTimeRanges, blockStart xtime.UnixNano, blockEnd xtime.UnixNano, ) (result.IndexBlock, error)
PersistBootstrapIndexSegment is a helper function that persists bootstrapped index segments for a ns -> block of time.
Types ¶
type EnqueueReadersOptions ¶ added in v0.15.9
type EnqueueReadersOptions struct { NsMD namespace.Metadata RunOpts bootstrap.RunOptions RuntimeOpts runtime.Options FsOpts fs.Options ShardTimeRanges result.ShardTimeRanges ReaderPool *ReaderPool ReadersCh chan<- TimeWindowReaders BlockSize time.Duration ReadMetadataOnly bool Logger *zap.Logger Span opentracing.Span NowFn clock.NowFn Cache bootstrap.Cache }
EnqueueReadersOptions supplies options to enqueue readers.
type NewReaderPoolOptions ¶ added in v0.15.0
type NewReaderPoolOptions struct { Alloc ReaderPoolAllocFn DisableReuse bool }
NewReaderPoolOptions contains reader pool options.
type ReaderPool ¶ added in v0.15.0
ReaderPool is a lean pool that does not allocate instances up front and is used per bootstrap call.
func NewReaderPool ¶ added in v0.15.0
func NewReaderPool( opts NewReaderPoolOptions, ) *ReaderPool
NewReaderPool creates a new share-able fileset reader pool
func (*ReaderPool) Get ¶ added in v0.15.0
func (p *ReaderPool) Get() (fs.DataFileSetReader, error)
Get gets a fileset reader from the pool in synchronized fashion.
func (*ReaderPool) Put ¶ added in v0.15.0
func (p *ReaderPool) Put(r fs.DataFileSetReader)
Put returns a fileset reader back the the pool in synchronized fashion.
type ReaderPoolAllocFn ¶ added in v0.15.0
type ReaderPoolAllocFn func() (fs.DataFileSetReader, error)
ReaderPoolAllocFn allocates a new fileset reader.
type ShardReaders ¶ added in v0.15.0
type ShardReaders struct {
Readers []fs.DataFileSetReader
}
ShardReaders are the fileset readers for a shard.
type ShardTimeRangesTimeWindowGroup ¶ added in v0.15.0
type ShardTimeRangesTimeWindowGroup struct { Ranges result.ShardTimeRanges // contains filtered or unexported fields }
ShardTimeRangesTimeWindowGroup represents all time ranges for every shard w/in a block of time.
func NewShardTimeRangesTimeWindowGroups ¶ added in v0.15.0
func NewShardTimeRangesTimeWindowGroups( shardTimeRanges result.ShardTimeRanges, windowSize time.Duration, ) []ShardTimeRangesTimeWindowGroup
NewShardTimeRangesTimeWindowGroups divides shard time ranges into grouped blocks.
type SharedCompactor ¶ added in v0.15.0
type SharedCompactor struct {}
SharedCompactor is a lockable compactor that's safe to be shared across threads.
type SharedPersistManager ¶ added in v0.15.0
type SharedPersistManager struct {}
SharedPersistManager is a lockable persist manager that's safe to be shared across threads.
type TimeWindowReaders ¶ added in v0.15.0
type TimeWindowReaders struct { Ranges result.ShardTimeRanges Readers map[ShardID]ShardReaders }
TimeWindowReaders are grouped by data block.
Directories ¶
Path | Synopsis |
---|---|
Package commitlog implements commit log bootstrapping.
|
Package commitlog implements commit log bootstrapping. |
Package fs implements file system bootstrapping.
|
Package fs implements file system bootstrapping. |
Package peers implements peers bootstrapping.
|
Package peers implements peers bootstrapping. |
Package uninitialized implements uninitialized topology bootstrapping.
|
Package uninitialized implements uninitialized topology bootstrapping. |