Class LogMergePolicy
This class implements a Merge
This class is abstract and requires a subclass to
define the Size(Segment
Inherited Members
Namespace:
Assembly: Lucene.Net.NetCore.dll
Syntax
public abstract class LogMergePolicy : MergePolicy
Constructors
Name | Description |
---|---|
Log |
Fields
Name | Description |
---|---|
DEFAULT_MAX_MERGE_DOCS | Default maximum segment size. A segment of this size |
DEFAULT_MERGE_FACTOR | Default merge factor, which is how many segments are merged at a time |
DEFAULT_NO_CFS_RATIO | Default noCFSRatio. If a merge's size is >= 10% of
the index, then we disable compound file for it.
See No |
internal |
|
internal |
|
LEVEL_LOG_SPAN | Defines the allowed range of log(size) for each level. A level is computed by taking the max segment log size, minus LEVEL_LOG_SPAN, and finding all segments falling within that range. |
Properties
Name | Description |
---|---|
Calibrate |
Gets or sets whether the segment size should be calibrated by the number of deletes when choosing segments for merge. |
Max |
Gets or sets the largest segment (measured by document count) that may be merged with other segments. Determines the largest segment (measured by document count) that may be merged with other segments. Small values (e.g., less than 10,000) are best for interactive indexing, as this limits the length of pauses while indexing to a few seconds. Larger values are best for batched indexing and speedier searches.
The default value is
The default merge policy (Log
|
Merge |
Gets or sets how often segment indices are merged by addDocument(). With smaller values, less RAM is used while indexing, and searches on unoptimized indices are faster, but indexing speed is slower. With larger values, more RAM is used during indexing, and while searches on unoptimized indices are slower, indexing is faster. Thus larger values (> 10) are best for batch index creation, and smaller values (< 10) for indices that are interactively maintained. |
No |
Methods
Name | Description |
---|---|
Find |
Checks if any merges are now necessary and returns a
Merge |
FindMergesForOptimize(SegmentInfos, Int32, ISet<SegmentInfo>) | Returns the merges necessary to optimize the index.
This merge policy defines "optimized" to mean only one
segment in the index, where that segment has no
deletions pending nor separate norms, and it is in
compound file format if the current useCompoundFile
setting is true. This method returns multiple merges
(mergeFactor at a time) so the Merge |
Find |
Finds merges necessary to expunge all deletes from the index. We simply merge adjacent segments that have deletes, up to mergeFactor at a time. |
Get |
Returns true if newly flushed and newly merge doc store segment files (term vectors and stored fields) |
Get |
|
Make |
|
Set |
Sets whether compound file format should be used for newly flushed and newly merged doc store segment files (term vectors and stored fields). |
Set |
Gets or sets whether compound file format should be used for newly flushed and newly merged segments. |
Size(Segment |
|
Size |
|
Size |
|
Use |
|
Use |
|
Verbose() |