index

package
v0.0.0-...-d0be9ee Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2015 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlcoholicMergePolicy

type AlcoholicMergePolicy struct {
	*LogMergePolicy
	// contains filtered or unexported fields
}

Merge policy for testing, it is like an alcoholic. It drinks (merges) at night, and randomly decides what to drink. During the daytime it sleeps.

If tests pass with this, then they are likely to pass with any bizarro merge policy users might write.

It is a fine bottle of champagne (Ordered by Martijn)

func NewAlcoholicMergePolicy

func NewAlcoholicMergePolicy(r *rand.Rand) *AlcoholicMergePolicy

func (*AlcoholicMergePolicy) Size

func (p *AlcoholicMergePolicy) Size(info *SegmentCommitInfo,
	writer *IndexWriter) (int64, error)

type MockRandomMergePolicy

type MockRandomMergePolicy struct {
	*MergePolicyImpl
	// contains filtered or unexported fields
}

MergePolicy that makes random decisions for testing.

func NewMockRandomMergePolicy

func NewMockRandomMergePolicy(r *rand.Rand) *MockRandomMergePolicy

func (*MockRandomMergePolicy) Close

func (p *MockRandomMergePolicy) Close() error

func (*MockRandomMergePolicy) FindForcedMerges

func (p *MockRandomMergePolicy) FindForcedMerges(segmentsInfos *SegmentInfos,
	maxSegmentCount int, segmentsToMerge map[*SegmentCommitInfo]bool,
	writer *IndexWriter) (MergeSpecification, error)

func (*MockRandomMergePolicy) FindMerges

func (p *MockRandomMergePolicy) FindMerges(mergeTrigger MergeTrigger,
	segmentInfos *SegmentInfos, writer *IndexWriter) (MergeSpecification, error)

func (*MockRandomMergePolicy) UseCompoundFile

func (p *MockRandomMergePolicy) UseCompoundFile(infos *SegmentInfos,
	mergedInfo *SegmentCommitInfo, writer *IndexWriter) (bool, error)

Jump to

Keyboard shortcuts

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