Commit Graph

193 Commits

Author SHA1 Message Date
Stefan Miklosovic 50960a2e7e
Remove 4.0 upgrade paths and related 4.0 tests
patch by Stefan Miklosovic; reviewed by Michael Semb Wever for CASSANDRA-21324
2026-06-02 23:54:38 +02:00
Stefan Miklosovic 82c6f8aa44
Merge branch 'cassandra-6.0' into trunk 2026-04-21 12:51:13 +02:00
Stefan Miklosovic e193523a06
Update 6.0 and 7.0 branches to reflect their versions across the project.
In 6.0, only rename test/data/serialization/5.1 to 6.0
In 7.0, same plus update edges in UpgradeTestBase

patch by Stefan Miklosovic; reviewed by Dmitry Konstantinov for CASSANDRA-21319
2026-04-21 12:46:11 +02:00
mck 6590cb5aaf
Change trunk from 5.1 to 6.0
patch by Mick Semb Wever; reviewed by Dmitry Konstantinov for CASSANDRA-21243
2026-03-21 22:55:40 +01:00
Dmitry Konstantinov a93f0819e3 Merge branch 'cassandra-5.0' into trunk
* cassandra-5.0:
  Add LittleEndianMemoryUtil and NativeEndianMemoryUtil, switch memtable-related off-heap objects and Memory to use them and have Little Endian now. Add BE offsets detection on Summary loading. Add test SSTables in an old format with BE offsets in Summary component to LegacySSTableTest.
2025-04-24 12:20:09 +01:00
Dmitry Konstantinov ae82efc013 Add LittleEndianMemoryUtil and NativeEndianMemoryUtil, switch memtable-related off-heap objects and Memory to use them and have Little Endian now.
Add BE offsets detection on Summary loading.
Add test SSTables in an old format with BE offsets in Summary component to LegacySSTableTest.

Patch by Dmitry Konstantinov; reviewed by Branimir Lambov, Michael Semb Wever for CASSANDRA-20190
2025-04-24 11:45:26 +01:00
David Capwell f87c22cbbd Rebase fixup: SerializationsTest needed to recreate the service.SyncComplete.bin file 2025-04-17 11:59:51 -07:00
Ariel Weisberg c10c84b9cd Accord/non-Accord interoperability and support for live migration
Patch by Ariel Weisberg; Reviewed by Blake Eggleston for CASSANDRA-18129

Co-authored-by: Blake Eggleston <beggleston@apple.com>
2025-04-17 11:59:49 -07:00
Ariel Weisberg 82acd3e950 Allow exceptions to be propagated remotely
https://github.com/apache/cassandra-accord/pull/56

Patch by Ariel Weisberg; Reviewed by David Capwell for CASSANDRA-18779
2025-04-17 11:59:48 -07:00
David Capwell 8633a301f7 CEP-15: (C*) Accord message processing should avoid being passed on to a Stage and run directly in the messageing handler
patch by David Capwell; reviewed by Ariel Weisberg, Benedict Elliott Smith for CASSANDRA-18364
2025-04-17 11:59:48 -07:00
Mick Semb Wever 607fae54b3
Merge branch 'cassandra-5.0' into trunk
* cassandra-5.0:
  Add LegacySSTableTest data for past sstable formats
  Fix comment in BigFormat wrt when nb was introduced
2025-03-28 12:45:51 +01:00
Roxana Neophytou ab51b79473
Add LegacySSTableTest data for past sstable formats
Also add test method testVerifyOldTupleSSTables for frozen tuples and dropping of them.

The test data also adds different versions of me format sstables from C* version 3.0.25 and 3.11.11 as they do (unfortunately) differ. Test sstable files have had their sequence generation ids changed to represent the server version used to create them, while this shouldn't be necessary it is for debug purposes when sstable formats have changed between versions.

 patch by Roxana Neophytou, Mick Semb Wever; reviewed by Dmitry Konstantinov for CASSANDRA-20485

Co-authored-by: mck <mck@apache.org>
2025-03-28 12:33:28 +01:00
Marcus Eriksson b6eb5890da Optionally prevent tombstone purging during repair
patch by Marcus Eriksson, Abe Ratnofsky; reviewed by Jon Meredith for CASSANDRA-20071
2024-11-18 13:24:31 -07:00
mck 1defa0851f
Merge branch 'cassandra-5.0' into trunk
* cassandra-5.0:
  Use ParameterizedClass for all auth-related implementations
2024-10-09 13:53:48 +02:00
Tiago Alves 2dea5c7588
Use ParameterizedClass for all auth-related implementations
Uses ParameterizedClass for IAuthorizer, INetworkAuthorizer, and
IRoleManager implementations enabling those to be configurable from
parameters specified directly in cassandra.yaml.

Opportunistically makes consistent the initialization and setting of
all auth-related implementations and removes code duplication.

Notes:
 * IInternodeAuthenticator implementations are expected to be set as
   default directly in DatabaseDescriptor instead of done via
   AuthConfig.applyAuth(). This is assumed in tests and client logic.
   For instance ReconnectableSnitchHelperTest fetches this authenticator
   before calling daemonInitialize(). Also, BulkLoader fetches this
   directly when creating an outbound connection.
 * Changing this behavior in BulkLoader causes a cascade of changes.
   First, one would need to add AuthConfig.applyAuth() directly in
   clientInitialize() and then would need to enable all the additional
   classes that this change causes. Long term this might be justified
   as if we're depending on the auth logic to be properly set. However,
   in the context of this change it was decided to postpone further
   changes.
 * Standardize auth-related configurations by using a short-form with
   the class name instead of the full qualified class name containing
   the package name.

 patch by Tiago Alves; reviewed by Mick Semb Wever, Stefan Miklosovic for CASSANDRA-19946
2024-10-09 13:51:51 +02:00
Sam Tunnicliffe 2c00371088 Push down repair tokens and partitioner through paxos repair
Patch by Sam Tunnicliffe; reviewed by Marcus Eriksson for
CASSANDRA-19714
2024-07-10 14:16:23 +01:00
Sam Tunnicliffe 51d048a93a Add cluster metadata id to gossip syn messages
Patch by Sam Tunnicliffe; reviewed by Marcus Eriksson for
CASSANDRA-19613
2024-05-03 09:21:10 +01:00
Jacek Lewandowski d9192745bc Merge branch 'cassandra-5.0' into trunk
* cassandra-5.0:
  Fix few types issues and implement types compatibility tests
2024-04-18 12:38:03 +02:00
Jacek Lewandowski 82297b490e Merge branch 'cassandra-4.1' into cassandra-5.0
* cassandra-4.1:
  Fix few types issues and implement types compatibility tests
2024-04-18 12:33:55 +02:00
Jacek Lewandowski 445ae1a4b1 Merge branch 'cassandra-4.0' into cassandra-4.1
* cassandra-4.0:
  Fix few types issues and implement types compatibility tests
2024-04-18 12:33:54 +02:00
Jacek Lewandowski f92998190c Fix few types issues and implement types compatibility tests
Patch by Jacek Lewandowski; reviewed by Stefan Miklosovic for CASSANDRA-19479
2024-04-18 12:33:52 +02:00
Sam Tunnicliffe 728b9ec4c6 Revisit metadata log schema to remove period field
Patch by Sam Tunnicliffe and Marcus Eriksson; reviewed by Alex Petrov for CASSANDRA-19482

Co-authored-by: Marcus Eriksson <marcuse@apache.org>
Co-authored-by: Sam Tunnicliffe <samt@apache.org>
2024-04-11 09:06:36 +01:00
Francisco Guerrero a0af41f666 CASSANDRA-18951: Add option for MutualTlsAuthenticator to restrict the certificate validity period
In this commit, we introduce two new optional options for the `server_encryption_options`
and the `client_encryption_options`. The options are `max_certificate_validity_period` and
`certificate_validity_warn_threshold`. Both options can be configured as a duration
configuration parameter as defined by the `DurationSpec` (see CASSANDRA-15234). The resolution
for these new properties is minutes.

When specified, the certificate validation implementation will take that information
and reject certificates that are older than the maximum allowed certificate validity period,
translating into a rejection from the authenticating user.

The `certificate_validity_warn_threshold` option can be configured to emit warnings (log entries)
when the certificate exceeds the validity threshold.

patch by Francisco Guerrero; reviewed by Andy Tolbert, Abe Ratnofsky, Dinesh Joshi for CASSANDRA-18951
2024-03-25 16:58:36 -07:00
Alex Petrov e182744cd0 Introduce 5.1 messaging format that brings in Epoch
Patch by Alex Petrov; reviewed by Sam Tunnicliffe CASSANDRA-19066.
2023-12-01 13:02:33 +01:00
Stefan Miklosovic 2004c17b60
Merge branch 'cassandra-4.1' into cassandra-5.0 2023-11-20 10:42:35 +01:00
Stefan Miklosovic 5b3c36b28a
Merge branch 'cassandra-4.1' into cassandra-5.0 2023-11-08 14:29:48 +01:00
Stefan Miklosovic 4ecff92404
Remove deprecated code in Cassandra 1.x and 2.x
patch by Stefan Miklosovic; reviewed by Brandon Williams for CASSANDRA-18959
2023-10-30 21:54:55 +01:00
Mike Adamson 949b760f55
Add support for a vector search index in SAI
- Adds jbellis/jvector (1.0.2) library for DiskANN based indexes on floating point vectors
- Adds ORDER BY ANN OF capability to do ANN search and order the results by score

 patch by Mike Adamson; reviewed by Andrés de la Peña, Jonathon Ellis for CASSANDRA-18715

Co-authored-by Jonathon Ellis jbellis@gmail.com
Co-authored-by Zhao Yang zhaoyangsingapore@gmail.com
2023-10-29 12:24:00 +01:00
Mick Semb Wever 865954fd99
Merge branch 'cassandra-4.1' into cassandra-5.0
* cassandra-4.1:
  Missing license info and headers
2023-08-31 22:43:33 +02:00
Mick Semb Wever 20125c5053
Merge branch 'cassandra-4.0' into cassandra-4.1
* cassandra-4.0:
  Missing license info and headers
2023-08-31 22:41:56 +02:00
Stefan Miklosovic 7b89b6018d
Remove commitlog_sync_batch_window_in_ms
patch by Stefan Miklosovic; reviewed by Brandon Williams for CASSANDRA-17161
2023-08-09 20:04:34 +02:00
Stefan Miklosovic fe9ad77fd7
Merge branch 'cassandra-4.1' into trunk 2023-08-02 18:39:56 +02:00
Stefan Miklosovic b94436c783
update ConfigCompatibility test
patch by Stefan Miklosovic; reviewed by David Capwell for CASSANDRA-18713
2023-08-02 18:35:41 +02:00
Bereng 2a458ba01d Improved DeletionTime serialization 2023-07-26 10:47:22 +02:00
KowalczykBartek 8faa2a2c69 Remove WaitingOnFreeMemtableSpace and DroppedMutations metrics
Patch by Bartlomiej, reviewed by bereng and brandonwilliams for
CASSANDRA-18298
2023-07-24 05:53:39 -05:00
Branimir Lambov 957eca2fb5 Implementation of the Unified Compaction Strategy as described in CEP-26
The approach is documented in the included UnifiedCompactionStrategy.md.

Also included:
- Generalize prettyPrint to prettyPrintBinary (with 2^10 multiplier,
  e.g. MiB) and prettyPrintDecimal (with 1000 multiplier, e.g. ms)
  that cover the full range of double, and add a parseHumanReadable
  method that can read both.

- CASSANDRA-18123: Fix invalid reuse of metadata collector during flushing

- Fix invalid token range splitting with non-unit weights

- Add flushSizeOnDisk metric

- Add ability to change compaction default in YAML

patch by Alex Sorokoumov, Branimir Lambov, Dimitar Dimitrov and Stefania Alborghetti
reviewed by Alex Sorokoumov, Jaroslaw Grabowski and Maxwell Guo for CASSANDRA-18397
2023-07-19 11:22:32 +03:00
Bereng 1adbea5a06 Extend maximum expiration date
patch by Berenguer Blasi; reviewed by Andrés de la Peña for CASSANDRA-14227
2023-06-05 07:18:34 +02:00
Jacek Lewandowski f16fb6765b Implementation of the trie-indexed SSTable format (BTI) as described in CEP-25.
Documentation in the included BTIFormat.md.

patch by Branimir Lambov and Jacek Lewandowski; reviewed by Caleb Rackliffe and Maxwell Guo for CASSANDRA-18398
2023-05-29 16:59:05 +03:00
Mick Semb Wever 7ca806c60a
Change trunk from 4.2 to 5.0
– update MessagingService (remove the 4.1 version that was only a placeholder in test code bc serialisation test files were previously incorrectly serialising random UUIds for TimeUUIDs)
 – update upgrade jvm-dtests
 – remove older serialization binary files we are no longer testing against

 patch by Mick Semb Wever; reviewed by Brandon Williams for CASSANDRA-17973
2023-03-07 11:03:38 +01:00
Jacek Lewandowski 24ebd24c79 More accurate skipping of sstables in read path
This patch improves the following things:
1. SSTable metadata will store a covered slice instead of min/max clusterings. The difference is that for slices there is available the type of a bound rather than just a clustering. In particular it will provide the information whether the lower and upper bound of an sstable is opened or closed.
2. SSTable metadata will store a flag whether the SSTable contains any partition level deletions or not
3. The above two changes required to introduce a new major format for SSTables - oa
4. Single partition read command makes use of the above changes. In particular an sstable can be skipped when it does not intersect with the column filter, does not have partition level deletions and does not have statics; In case there are partition level deletions, but the other conditions are satisfied, only the partition header needs to be accessed (tests attached)
5. Skipping SSTables assuming those three conditions are satisfied has been implemented also for partition range queries (tests attached). Also added minor separate statistics to record the number of accessed sstables in partition reads because now not all of them need to be accessed.
6. Artificial lower bound marker is now an object on its own and is not implemented as a special case of range tombstone bound.
7. Extended the lower bound optimization usage due the 1 and 2
8. Do not initialize iterator just to get a cached partition and associated columns index. The purpose of using lower bound optimization was to avoid opening an iterator of an sstable if possible.
9. Add key range to stats metadata

[f369595b1c] Add fields to sstable version and placeholders in stats serializer
[f5c3f772e2] Add hasKeyRange and hasLegacyMinMax
[3cde51f4e1] Add partition level deletion presence marker to sstable stats
[67b2ee2152] Extract AbstractTypeSerializer
[c77b475d6c] Refactor slices intersection checking
[ceb5af3a38] Store min and max clustering as a slice in stats metadata as and improved min/max
[d1f8973929] Implement MetadataCollectorBench
[335369da84] Apply partition level deletion presence marker optimizations to single partition read command
[2497a009b9] Lower bound optimization - add slices and isReverseOrder fields to UnfilteredRowIteratorWithLowerBound
[e32ee31177] Lower bound optimization - Replace usage of RangeTombstoneMarker as a lower bound with ArtificialBoundMarker
[e213e712c4] Lower bound optimization - improve usage of lower bound optimization
[c4f93006b1] Apply read path improvements to partition range queries
[5fa462266c] Add key range to StatsMetadata
[79a7339ed4] Use key range from stats if possible
[266ed2749b] Added new sstables for LegacySSTableTest

patch by Jacek Lewandowski; reviewed by Branimir Lambov and C. Scott Andreas for CASSANDRA-18134

Co-authored-by: Branimir Lambov <blambov>
Co-authored-by: Sylvain Lebresne <pcmanus>
Co-authored-by: Jacek Lewandowski <jacek-lewandowski>
Co-authored-by: Jakub Zytka <jakubzytka>
2023-02-21 09:41:07 +01:00
David Capwell 3409e5d9b3 Enhance SnakeYAML properties to be reusable outside of YAML parsing, support camel case conversion to snake case, and add support to ignore properties
patch by David Capwell; reviewed by Caleb Rackliffe, Stefan Miklosovic for CASSANDRA-17166
2022-04-22 20:17:45 -07:00
Andrés de la Peña cd870fe645 Merge branch 'cassandra-4.0' into trunk 2022-03-25 13:13:42 +00:00
jacek-lewandowski 05fa92475c Remove accidentally committed wrong legacy sstables
patch by Jacek Lewandowski; reviewed by Andrés de la Peña and Benjamin Lerer for CASSANDRA-17482
2022-03-25 13:09:34 +00:00
Jacek Lewandowski 0040fea379 Implement sstable generation identifier as uuid
Patch by Jacek Lewandowski; reviewed by Andrés de la Peña, Benjamin Lerer and Dan Jatnieks for CASSANDRA-17048
2022-03-23 11:50:33 +00:00
Benedict Elliott Smith d2923275e3 CEP-14: Paxos Improvements
This work encompasses a range of improvements to Paxos, summarised as:

 - The introduction of Paxos Repair for ensuring consistency during range movements
 - The reduction of network round-trips by a factor of 2x for reads and writes

patch by Benedict Elliott Smith and Blake Eggleston; reviewed by Alex Petrov, Aleksey Yeschenko and Sam Tunnicliffe for CASSANDRA-17164
2022-03-10 16:30:12 +00:00
jacek-lewandowski d35f36cd05 Fix misplacement of originatingHostId in stats metadata
patch by Jacek Lewandowski; reviewed by Benjamin Lerer for CASSANDRA-16619
2021-05-17 10:36:55 +02:00
Benjamin Lerer c4fab930ca Merge branch cassandra-3.11 into cassandra-4.0 2021-05-06 11:45:47 +02:00
Benjamin Lerer d6ff4c4a35 Merge branch cassandra-3.0 into cassandra-3.11 2021-05-06 11:32:47 +02:00
jacek-lewandowski d84c6e9810 Prevent loss of commit log data when moving sstables between nodes
patch by Jakub Zytka and Jacek Lewandowski; reviewed by Branimir Lambov and Benjamin Lerer for CASSANDRA-16619

Add originating host ID to sstable metadata

- md, me sstables
- add missing test cases in MetadataSerializerTest

Co-authored-by: Jakub Zytka <jakub.zytka@datastax.com>
Co-authored-by: Jacek Lewandowski <jacek.lewandowski@datastax.com>
2021-05-05 16:41:01 +02:00
Mick Semb Wever 7337fc0ab4
Merge branch 'cassandra-3.11' into trunk 2021-04-19 17:39:10 +02:00