Module org.elasticsearch.server
Interface DocumentSizeAccumulator
public interface DocumentSizeAccumulator
An interface to allow accumulating results of document parsing (collected with
XContentParserDecorator
)-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(long size) Accumulates the reported size of the documentgetAsCommitUserData
(org.apache.lucene.index.SegmentInfos segmentInfos) Returns a map with an entry being the current state of the accumulator + previously commited value for that key Then resets the accumulator.
-
Field Details
-
EMPTY_INSTANCE
-
-
Method Details
-
add
void add(long size) Accumulates the reported size of the document- Parameters:
size
- the size of the doc
-
getAsCommitUserData
Returns a map with an entry being the current state of the accumulator + previously commited value for that key Then resets the accumulator.- Parameters:
segmentInfos
- a shard's previously comited SegmentInfos- Returns:
- an map with a new value of size
-