Class MapRecord
- java.lang.Object
-
- org.apache.jackrabbit.oak.segment.MapRecord
-
public class MapRecord extends Object
A map. The top level record is either a record of type "BRANCH" or "LEAF" (depending on the data).
-
-
Field Summary
Fields Modifier and Type Field Description protected static intBITS_PER_LEVELNumber of bits of the hash code to look at on each level of the trie.protected static intBUCKETS_PER_LEVELNumber of buckets at each level of the trie.protected static intERROR_SIZEGoing over this limit will generate an error message in the logprotected static intERROR_SIZE_DISCARD_WRITESGoing over this limit will generate an error message in the log and won't allow writes unlessoak.segmentNodeStore.allowWritesOnHugeMapRecordsystem property is set.protected static intERROR_SIZE_HARD_STOPGoing over this limit will generate an error message in the log and won't allow any writes whatsoever.protected static intLEVEL_BITSNumber of bits needed to indicate the current trie level.protected static intMAX_NUMBER_OF_LEVELSMaximum number of trie levels.protected static intMAX_SIZEMaximum size of a map.protected static intSIZE_BITSNumber of bits used to indicate the size of a map.protected static intWARN_SIZEGoing over this limit will generate a warning message in the log
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object that)@NotNull GCGenerationgetGcGeneration()Get the underlying segment's gc generation.RecordIdgetRecordId()Returns the identifier of this record.protected intgetRecordNumber()protected SegmentgetSegment()Returns the segment that contains this record.inthashCode()booleanisDiff()StringtoString()
-
-
-
Field Detail
-
BITS_PER_LEVEL
protected static final int BITS_PER_LEVEL
Number of bits of the hash code to look at on each level of the trie.- See Also:
- Constant Field Values
-
BUCKETS_PER_LEVEL
protected static final int BUCKETS_PER_LEVEL
Number of buckets at each level of the trie.- See Also:
- Constant Field Values
-
MAX_NUMBER_OF_LEVELS
protected static final int MAX_NUMBER_OF_LEVELS
Maximum number of trie levels.- See Also:
- Constant Field Values
-
LEVEL_BITS
protected static final int LEVEL_BITS
Number of bits needed to indicate the current trie level. Currently 4.
-
SIZE_BITS
protected static final int SIZE_BITS
Number of bits used to indicate the size of a map. Currently 28.
-
MAX_SIZE
protected static final int MAX_SIZE
Maximum size of a map.
-
WARN_SIZE
protected static final int WARN_SIZE
Going over this limit will generate a warning message in the log- See Also:
- Constant Field Values
-
ERROR_SIZE
protected static final int ERROR_SIZE
Going over this limit will generate an error message in the log- See Also:
- Constant Field Values
-
ERROR_SIZE_DISCARD_WRITES
protected static final int ERROR_SIZE_DISCARD_WRITES
Going over this limit will generate an error message in the log and won't allow writes unlessoak.segmentNodeStore.allowWritesOnHugeMapRecordsystem property is set.- See Also:
- Constant Field Values
-
ERROR_SIZE_HARD_STOP
protected static final int ERROR_SIZE_HARD_STOP
Going over this limit will generate an error message in the log and won't allow any writes whatsoever. MoreoverUnsupportedOperationExceptionwill be thrown.- See Also:
- Constant Field Values
-
-
Method Detail
-
isDiff
public boolean isDiff()
-
toString
public String toString()
-
getSegment
protected Segment getSegment()
Returns the segment that contains this record.- Returns:
- segment that contains this record
-
getRecordNumber
protected int getRecordNumber()
-
getRecordId
public RecordId getRecordId()
Returns the identifier of this record.- Returns:
- record identifier
-
getGcGeneration
@NotNull public @NotNull GCGeneration getGcGeneration()
Get the underlying segment's gc generation. Might cause the segment to get loaded if the generation info is missing- Returns:
- the segment's gc generation
-
-