CASSANDRA-20012: Finalize blob SAI support for the 6.0 target

Fix regressions introduced by the cassandra-5.0 -> cassandra-6.0 rebase
and address review feedback:

 * Restore IndexTermType.isEqOnlyType(AbstractType), which the rebase
   silently dropped. The method is unused in 5.0 but is still called by
   6.0 test infrastructure (CreateIndexDDL, SingleNodeSAITestBase), so
   its removal broke the build.
 * Fix the sort order of the sai_blob_term_size_* rows in the
   GuardrailsConfigCommandsTest verbose expected output.
 * Restore the two trailing blank lines at the end of CHANGES.txt that
   were accidentally deleted.
 * Place the CHANGES.txt entry in the middle of the 6.0-alpha2 section
   rather than the top, which is the most merge-conflict-prone position.
 * SAI FAQ: note that BLOB support is new in Cassandra 6.0 (was 5.0.7).
 * Revert the accidental end-of-file newline change in sai-faq.adoc.

Assisted-by: Claude:claude-opus-4-8
This commit is contained in:
Terry Moschou 2026-08-02 17:51:49 +09:30
parent f9be27e0ac
commit df972e8680
4 changed files with 9 additions and 4 deletions

View File

@ -1,5 +1,4 @@
6.0-alpha2
* Add blob type support to SAI (CASSANDRA-20012)
* Apply performance optimizations for rows merging logic (CASSANDRA-21524)
* Fix operationMode reporting DECOMMISSION_FAILED instead of LEAVING when resuming a failed decommission (CASSANDRA-21493)
* Avoid megamorphic calls when serializing and deserializing fixed-length values (CASSANDRA-21536)
@ -36,6 +35,7 @@
* Safely regain ranges and delete retired command stores (CASSANDRA-21212)
* Reduce memory allocations in miscellaneous places along read path (CASSANDRA-21360)
* Avoid ByteBuffer wrapping in cql3.selection.Selector.InputRow to reduce memory allocation rate (CASSANDRA-21362)
* Add blob type support to SAI (CASSANDRA-20012)
* Reduce cost to calculate BTreeRow.minDeletionTime (CASSANDRA-21414)
* Implement custom CassandraThread to keep direct references to frequently used thread local objects (CASSANDRA-21020)
* Avoid megamorphic call overhead at RandomAccessReader#current (CASSANDRA-21399)

View File

@ -161,7 +161,7 @@ The supported types are: `ASCII, BIGINT, BLOB, BOOLEAN, DATE, DECIMAL, DOUBLE, F
[NOTE]
====
* The `BLOB` support was new starting with Cassandra 5.0.7.
* The `BLOB` support was new starting with Cassandra 6.0.
* SAI also supports collections -- see the xref:#saiCollectionColumnFaq[next FAQ].
====
@ -348,4 +348,4 @@ SAI returns `InvalidRequestException` if you try to define an index on a column
== What partitioner does SAI support?
SAI supports only the `Murmur3Partitioner`.
SAI supports only the `Murmur3Partitioner`.

View File

@ -346,6 +346,11 @@ public class IndexTermType
return this.columnMetadata.compareTo(columnMetadata) == 0;
}
public static boolean isEqOnlyType(AbstractType<?> type)
{
return EQ_ONLY_TYPES.contains(type);
}
/**
* Indicates if the type encoding supports rounding of the raw value.
* <p>

View File

@ -301,8 +301,8 @@ public class GuardrailsConfigCommandsTest extends CQLTester
"partition_tombstones_fail_threshold -1 \n" +
"partition_tombstones_warn_threshold -1 \n" +
"sai_blob_term_size_fail_threshold 8KiB \n" +
"sai_frozen_term_size_fail_threshold 8KiB \n" +
"sai_blob_term_size_warn_threshold 1KiB \n" +
"sai_frozen_term_size_fail_threshold 8KiB \n" +
"sai_frozen_term_size_warn_threshold 1KiB \n" +
"sai_sstable_indexes_per_query_fail_threshold -1 \n" +
"sai_sstable_indexes_per_query_warn_threshold 32 \n" +