public class SegmentTracker extends Object
It is also responsible to cache segment objects in memory.
| Constructor and Description |
|---|
SegmentTracker(SegmentStore store) |
SegmentTracker(SegmentStore store,
int cacheSizeMB,
SegmentVersion version) |
SegmentTracker(SegmentStore store,
SegmentVersion version) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearCache()
Clear the caches
|
void |
clearSegmentIdTables(CompactionStrategy strategy) |
void |
collectBlobReferences(org.apache.jackrabbit.oak.plugins.blob.ReferenceCollector collector)
Finds all external blob references that are currently accessible
in this repository and adds them to the given collector.
|
SegmentWriter |
createSegmentWriter(String wid) |
CompactionMap |
getCompactionMap() |
Set<SegmentId> |
getReferencedSegmentIds()
Returns all segment identifiers that are currently referenced in memory.
|
org.apache.jackrabbit.oak.cache.CacheStats |
getSegmentCacheStats() |
SegmentId |
getSegmentId(long msb,
long lsb) |
SegmentStore |
getStore() |
org.apache.jackrabbit.oak.cache.CacheStats |
getStringCacheStats() |
SegmentWriter |
getWriter() |
void |
setCompactionMap(PartialCompactionMap map) |
public SegmentTracker(SegmentStore store, int cacheSizeMB, SegmentVersion version)
public SegmentTracker(SegmentStore store, SegmentVersion version)
public SegmentTracker(SegmentStore store)
public final SegmentWriter createSegmentWriter(String wid)
SegmentWriter instance for writing to this store.@Nonnull public org.apache.jackrabbit.oak.cache.CacheStats getSegmentCacheStats()
@CheckForNull public org.apache.jackrabbit.oak.cache.CacheStats getStringCacheStats()
public SegmentWriter getWriter()
public SegmentStore getStore()
public void clearCache()
public void setCompactionMap(PartialCompactionMap map)
@Nonnull public CompactionMap getCompactionMap()
public Set<SegmentId> getReferencedSegmentIds()
public void collectBlobReferences(org.apache.jackrabbit.oak.plugins.blob.ReferenceCollector collector)
Note that this method only collects blob references that are already stored in the repository (at the time when this method is called), so the garbage collector will need some other mechanism for tracking in-memory references and references stored while this method is running.
public SegmentId getSegmentId(long msb, long lsb)
msb - lsb - public void clearSegmentIdTables(CompactionStrategy strategy)
Copyright © 2012-2016 The Apache Software Foundation. All Rights Reserved.