This is an automated email from the ASF dual-hosted git repository.
bereng pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/cassandra.git
The following commit(s) were added to refs/heads/trunk by this push:
new 9aa2109803 Javadoc BigFormat
9aa2109803 is described below
commit 9aa2109803a6dd53db36b058e89e7b431762ded2
Author: Bereng <[email protected]>
AuthorDate: Thu Aug 24 11:19:57 2023 +0200
Javadoc BigFormat
patch by Berenguer Blasi; reviewed by Ling Mao, Stefan Miklosovic for
CASSANDRA-18786
---
.../cassandra/io/sstable/format/big/BigFormat.java | 97 +++++++++++++++++++++-
.../io/sstable/indexsummary/IndexSummary.java | 2 +
2 files changed, 97 insertions(+), 2 deletions(-)
diff --git a/src/java/org/apache/cassandra/io/sstable/format/big/BigFormat.java
b/src/java/org/apache/cassandra/io/sstable/format/big/BigFormat.java
index 4de58b4b6b..d40d6a6f07 100644
--- a/src/java/org/apache/cassandra/io/sstable/format/big/BigFormat.java
+++ b/src/java/org/apache/cassandra/io/sstable/format/big/BigFormat.java
@@ -38,13 +38,14 @@ import org.apache.cassandra.config.DatabaseDescriptor;
import org.apache.cassandra.db.ColumnFamilyStore;
import org.apache.cassandra.db.DecoratedKey;
import org.apache.cassandra.db.lifecycle.LifecycleTransaction;
+import org.apache.cassandra.db.memtable.Flushing;
import org.apache.cassandra.dht.IPartitioner;
import org.apache.cassandra.io.sstable.Component;
-import org.apache.cassandra.io.sstable.SSTable;
import org.apache.cassandra.io.sstable.Descriptor;
import org.apache.cassandra.io.sstable.GaugeProvider;
import org.apache.cassandra.io.sstable.IScrubber;
import org.apache.cassandra.io.sstable.MetricsProviders;
+import org.apache.cassandra.io.sstable.SSTable;
import org.apache.cassandra.io.sstable.filter.BloomFilterMetrics;
import org.apache.cassandra.io.sstable.format.AbstractSSTableFormat;
import org.apache.cassandra.io.sstable.format.SSTableFormat;
@@ -66,7 +67,99 @@ import org.apache.cassandra.utils.Pair;
import static
org.apache.cassandra.io.sstable.format.SSTableFormat.Components.DATA;
/**
- * Legacy bigtable format
+ * Legacy bigtable format. Components and approximate lifecycle:
+ * <br>
+ * {@link SSTableFormat.Components}
+ * <br>
+ * {@link Components#ALL_COMPONENTS}
+ * <ul>
+ * <li>
+ * {@link Components#SUMMARY}: When searching for a PK we go here for a
first approximation on where to look in the index file. It is
+ * a small sampling of the Index entries intended for a first fast
search in-memory.
+ * <p></p>
+ * {@link org.apache.cassandra.io.sstable.indexsummary.IndexSummary}
+ * <br>
+ * {@link IndexSummaryComponent}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#PRIMARY_INDEX}: We'll land here in the approximate
area where to look for the PK thanks to the Summary. Now we'll search for
+ * the exact PK to get it's exact position in the data file.
+ * <p></p>
+ * {@link BigTableWriter#indexWriter}
+ * <br>
+ * {@link RowIndexEntry}
+ * <br>
+ * {@link org.apache.cassandra.io.sstable.IndexInfo}
+ * <br>
+ * {@link org.apache.cassandra.io.sstable.format.IndexComponent}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#DATA}: The actual data/partitions file as an array
or partitions. Each partition has the form:
+ * <ul>
+ * <li>A partition header</li>
+ * <li>Maybe a static row</li>
+ * <li>Rows or range tombstone</li>
+ * </ul>
+ * I.e. upon flush {@link Flushing.FlushRunnable#writeSortedContents}
+ * <br>
+ * Down to {@link
org.apache.cassandra.io.sstable.format.SortedTableWriter#startPartition}
+ * <br>
+ * Down to {@link
org.apache.cassandra.io.sstable.format.SortedTablePartitionWriter#start}
+ * <br>
+ * {@link org.apache.cassandra.io.sstable.format.DataComponent}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#STATS}: Stats on the data such as min timestamps to
later vint encode TTL, markForDeleteAt, etc
+ * <p></p>
+ * {@link org.apache.cassandra.db.rows.EncodingStats}
+ * <br>
+ * {@link org.apache.cassandra.io.sstable.format.StatsComponent}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#COMPRESSION_INFO}: Contains compresion metadata
+ * <p></p>
+ * {@link org.apache.cassandra.io.compress.CompressedSequentialWriter}
+ * <br>
+ * {@link org.apache.cassandra.io.compress.CompressionMetadata}
+ * <br>
+ * {@link
org.apache.cassandra.io.sstable.format.CompressionInfoComponent}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#DIGEST}: The digest supporting the compression
+ * <p></p>
+ * {@link org.apache.cassandra.io.compress.CompressedSequentialWriter}
+ * <br>
+ * {@link org.apache.cassandra.io.util.ChecksumWriter}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#FILTER}: Bloom filter for data files
+ * <p></p>
+ * {@link org.apache.cassandra.io.sstable.format.FilterComponent}
+ * <br>
+ * {@link org.apache.cassandra.utils.BloomFilterSerializer}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#CRC}: CRC for the data
+ * <p></p>
+ * {@link org.apache.cassandra.io.util.ChecksummedSequentialWriter}
+ * <br>
+ * {@link org.apache.cassandra.io.util.ChecksumWriter}
+ * <p></p>
+ * </li>
+ * <li>
+ * {@link Components#TOC}: List of all the components for the SSTable
+ * <p></p>
+ * {@link org.apache.cassandra.io.sstable.format.TOCComponent}
+ * </li>
+ * </ul>
+ *
*/
public class BigFormat extends AbstractSSTableFormat<BigTableReader,
BigTableWriter>
{
diff --git
a/src/java/org/apache/cassandra/io/sstable/indexsummary/IndexSummary.java
b/src/java/org/apache/cassandra/io/sstable/indexsummary/IndexSummary.java
index 0d5ccb750b..3aa9fd9d8b 100644
--- a/src/java/org/apache/cassandra/io/sstable/indexsummary/IndexSummary.java
+++ b/src/java/org/apache/cassandra/io/sstable/indexsummary/IndexSummary.java
@@ -61,6 +61,8 @@ import static
org.apache.cassandra.io.sstable.Downsampling.BASE_SAMPLING_LEVEL;
* to find the position in the Memory to start reading the actual index
summary entry.
* (This is necessary because keys can have different lengths.)
* 2. A sequence of (DecoratedKey, position) pairs, where position is the
offset into the actual index file.
+ *
+ * See the serializer for the exact on disk details.
*/
public class IndexSummary extends WrappedSharedCloseable
{
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]