[ https://issues.apache.org/jira/browse/CASSANDRA-18119?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17952116#comment-17952116 ]
Marcus Eriksson commented on CASSANDRA-18119: --------------------------------------------- attached details for 5.0 and trunk > Handle sstable metadata stats file getting a new mtime after compaction has > finished > ------------------------------------------------------------------------------------ > > Key: CASSANDRA-18119 > URL: https://issues.apache.org/jira/browse/CASSANDRA-18119 > Project: Apache Cassandra > Issue Type: Bug > Components: Local/Compaction, Local/Startup and Shutdown > Reporter: Marcus Eriksson > Assignee: Marcus Eriksson > Priority: Normal > Fix For: 4.0.18, 4.1.9, 5.0.5 > > Attachments: ci_summary-4.1.html, ci_summary-trunk.html, > ci_summary_4.0.html, ci_summary_5.0.html, result_details-trunk.tar.gz, > result_details_5.0.tar.gz > > Time Spent: 2h > Remaining Estimate: 0h > > Due to a race between compaction finishing and compaction strategies getting > reloaded there is a chance that we try to add both the new sstable and the > old compacted sstable to the compaction strategy, and in the LCS case this > can cause the old sstable to get sent to L0 to avoid overlap. This changes > the mtime of the stats metadata file and if the node is shut down before the > sstable is actually deleted from disk, we fail starting with the following > exception: > {code} > .../mockcf1-392b3ff07c5a11ed8c662f5760cb10b3/nb_txn_compaction_3983c030-7c5a-11ed-8c66-2f5760cb10b3.log > REMOVE:[.../data/TransactionLogsTest/mockcf1-392b3ff07c5a11ed8c662f5760cb10b3/nb-0-big-,1671096247000,5][4003386800] > ***Unexpected files detected for sstable [nb-0-big-]: last update > time [Thu Dec 15 10:24:09 CET 2022] (1671096249000) should have been [Thu Dec > 15 10:24:07 CET 2022] (1671096247000) > ADD:[.../data/TransactionLogsTest/mockcf1-392b3ff07c5a11ed8c662f5760cb10b3/nb-2-big-,0,5][319189529] > {code} > A workaround for this (until we properly fix the way compaction strategies > get notified about sstable changes) is to ignore the timestamp of the STATS > component when cleaning up compaction leftovers on startup. -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org