This is an automated email from the ASF dual-hosted git repository. brandonwilliams pushed a commit to branch cassandra-3.11 in repository https://gitbox.apache.org/repos/asf/cassandra.git
commit 326b5aceb188912f377aac1e36485e0054605851 Merge: 4b84a8d7ac be574fc34b Author: Brandon Williams <brandonwilli...@apache.org> AuthorDate: Thu Mar 9 10:01:06 2023 -0600 Merge branch 'cassandra-3.0' into cassandra-3.11 CHANGES.txt | 1 + .../cassandra/service/DefaultFSErrorHandler.java | 2 + ...ava => JVMStabilityInspectorThrowableTest.java} | 72 ++++++++--- .../service/DefaultFSErrorHandlerTest.java | 121 ++++++++++++++++++ .../cassandra/service/DiskFailurePolicyTest.java | 135 +++++++++++++++++++++ .../org/apache/cassandra/utils/KillerForTests.java | 6 + 6 files changed, 322 insertions(+), 15 deletions(-) diff --cc CHANGES.txt index c00315d495,aa1e60427a..2812ae77d1 --- a/CHANGES.txt +++ b/CHANGES.txt @@@ -1,6 -1,5 +1,7 @@@ -3.0.29 +3.11.15 + * Fix Splitter sometimes creating more splits than requested (CASSANDRA-18013) +Merged from 3.0: + * Fix default file system error handler for disk_failure_policy die (CASSANDRA-18294) * Introduce check for names of test classes (CASSANDRA-17964) * Suppress CVE-2022-41915 (CASSANDRA-18147) * Suppress CVE-2021-1471, CVE-2021-3064, CVE-2021-4235 (CASSANDRA-18149) diff --cc test/distributed/org/apache/cassandra/distributed/test/JVMStabilityInspectorThrowableTest.java index b9e8d679b8,d7aeccaf6f..efe05ca1a6 --- a/test/distributed/org/apache/cassandra/distributed/test/JVMStabilityInspectorThrowableTest.java +++ b/test/distributed/org/apache/cassandra/distributed/test/JVMStabilityInspectorThrowableTest.java @@@ -181,19 -211,27 +212,25 @@@ public class JVMStabilityInspectorThrow private static final class CorruptedSSTableReader extends ForwardingSSTableReader { - public CorruptedSSTableReader(SSTableReader delegate) + private boolean shouldThrowCorrupted; + public CorruptedSSTableReader(SSTableReader delegate, boolean shouldThrowCorrupted) { super(delegate); + this.shouldThrowCorrupted = shouldThrowCorrupted; } - @Override - public SliceableUnfilteredRowIterator iterator(DecoratedKey key, ColumnFilter selectedColumns, boolean reversed, boolean isForThrift, SSTableReadsListener listener) + public UnfilteredRowIterator iterator(DecoratedKey key, Slices slices, ColumnFilter selectedColumns, boolean reversed, boolean isForThrift, SSTableReadsListener listener) { - throw throwCorrupted(); + if (shouldThrowCorrupted) + throw throwCorrupted(); + throw throwFSError(); } - @Override - public SliceableUnfilteredRowIterator iterator(FileDataInput file, DecoratedKey key, RowIndexEntry indexEntry, ColumnFilter selectedColumns, boolean reversed, boolean isForThrift) + public UnfilteredRowIterator iterator(FileDataInput file, DecoratedKey key, RowIndexEntry indexEntry, Slices slices, ColumnFilter selectedColumns, boolean reversed, boolean isForThrift) { - throw throwCorrupted(); + if (shouldThrowCorrupted) + throw throwCorrupted(); + throw throwFSError(); } private CorruptSSTableException throwCorrupted() diff --cc test/unit/org/apache/cassandra/utils/KillerForTests.java index fe9aa4599c,ad3a27436e..a802809722 --- a/test/unit/org/apache/cassandra/utils/KillerForTests.java +++ b/test/unit/org/apache/cassandra/utils/KillerForTests.java @@@ -42,9 -29,11 +42,15 @@@ public class KillerForTests extends JVM @Override protected void killCurrentJVM(Throwable t, boolean quiet) { + if (!expected) + Assert.fail("Saw JVM Kill but did not expect it."); + + if (killed) + { + // Can only be killed once + return; + } ++ this.killed = true; this.quiet = quiet; } --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org