public class MetadataCollector extends java.lang.Object implements PartitionStatisticsCollector
Modifier and Type | Class and Description |
---|---|
static class |
MetadataCollector.MinMaxIntTracker |
static class |
MetadataCollector.MinMaxLongTracker |
Modifier and Type | Field and Description |
---|---|
protected com.clearspring.analytics.stream.cardinality.ICardinality |
cardinality
Default cardinality estimation method is to use HyperLogLog++.
|
protected ReplayPosition |
commitLogLowerBound |
protected ReplayPosition |
commitLogUpperBound |
protected double |
compressionRatio |
protected EstimatedHistogram |
estimatedCellPerPartitionCount |
protected EstimatedHistogram |
estimatedPartitionSize |
protected StreamingHistogram |
estimatedTombstoneDropTime |
protected boolean |
hasLegacyCounterShards |
protected MetadataCollector.MinMaxIntTracker |
localDeletionTimeTracker |
protected java.nio.ByteBuffer[] |
maxClusteringValues |
protected java.nio.ByteBuffer[] |
minClusteringValues |
static double |
NO_COMPRESSION_RATIO |
protected int |
sstableLevel |
protected MetadataCollector.MinMaxLongTracker |
timestampTracker |
protected long |
totalColumnsSet |
protected long |
totalRows |
protected MetadataCollector.MinMaxIntTracker |
ttlTracker |
Constructor and Description |
---|
MetadataCollector(ClusteringComparator comparator) |
MetadataCollector(java.lang.Iterable<SSTableReader> sstables,
ClusteringComparator comparator,
int level) |
public static final double NO_COMPRESSION_RATIO
protected EstimatedHistogram estimatedPartitionSize
protected EstimatedHistogram estimatedCellPerPartitionCount
protected ReplayPosition commitLogLowerBound
protected ReplayPosition commitLogUpperBound
protected final MetadataCollector.MinMaxLongTracker timestampTracker
protected final MetadataCollector.MinMaxIntTracker localDeletionTimeTracker
protected final MetadataCollector.MinMaxIntTracker ttlTracker
protected double compressionRatio
protected StreamingHistogram estimatedTombstoneDropTime
protected int sstableLevel
protected java.nio.ByteBuffer[] minClusteringValues
protected java.nio.ByteBuffer[] maxClusteringValues
protected boolean hasLegacyCounterShards
protected long totalColumnsSet
protected long totalRows
protected com.clearspring.analytics.stream.cardinality.ICardinality cardinality
public MetadataCollector(ClusteringComparator comparator)
public MetadataCollector(java.lang.Iterable<SSTableReader> sstables, ClusteringComparator comparator, int level)
public static StatsMetadata defaultStatsMetadata()
public MetadataCollector addKey(java.nio.ByteBuffer key)
public MetadataCollector addPartitionSizeInBytes(long partitionSize)
public MetadataCollector addCellPerPartitionCount(long cellCount)
public MetadataCollector mergeTombstoneHistogram(StreamingHistogram histogram)
public MetadataCollector addCompressionRatio(long compressed, long uncompressed)
public void update(LivenessInfo newInfo)
update
in interface PartitionStatisticsCollector
public void update(Cell cell)
update
in interface PartitionStatisticsCollector
public void update(DeletionTime dt)
update
in interface PartitionStatisticsCollector
public void updateColumnSetPerRow(long columnSetInRow)
updateColumnSetPerRow
in interface PartitionStatisticsCollector
public MetadataCollector commitLogLowerBound(ReplayPosition commitLogLowerBound)
public MetadataCollector commitLogUpperBound(ReplayPosition commitLogUpperBound)
public MetadataCollector sstableLevel(int sstableLevel)
public MetadataCollector updateClusteringValues(ClusteringPrefix clustering)
public void updateHasLegacyCounterShards(boolean hasLegacyCounterShards)
updateHasLegacyCounterShards
in interface PartitionStatisticsCollector
public java.util.Map<MetadataType,MetadataComponent> finalizeMetadata(java.lang.String partitioner, double bloomFilterFPChance, long repairedAt, SerializationHeader header)
Copyright © 2016 The Apache Software Foundation