You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Marcus Eriksson (JIRA)" <ji...@apache.org> on 2015/03/31 11:05:54 UTC
[jira] [Assigned] (CASSANDRA-9070) Race in cancelling compactions
[ https://issues.apache.org/jira/browse/CASSANDRA-9070?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcus Eriksson reassigned CASSANDRA-9070:
------------------------------------------
Assignee: Marcus Eriksson
> Race in cancelling compactions
> ------------------------------
>
> Key: CASSANDRA-9070
> URL: https://issues.apache.org/jira/browse/CASSANDRA-9070
> Project: Cassandra
> Issue Type: Bug
> Reporter: Marcus Eriksson
> Assignee: Marcus Eriksson
> Fix For: 2.0.14
>
>
> seems we might have a race situation when cancelling compactions
> currently we do the following to ensure that we don't start any new compactions when we try to do markAllCompacting()
> # pause compactions - this makes sure we don't create any new compaction tasks from the compaction strategies
> # cancel any ongoing compactions - compactions register themselves with the CompactionMetrics and then, when cancelling we get all compactions here, and tell them to stop
> Problem is that there is a window between when the CompactionTask is created and when it is registered in CompactionMetrics meaning with a bit of bad luck, we could have a situation like this:
> # we finish a compaction and create a new CompactionTask from the compaction strategy
> # we pause the compaction strategies to not create any new CompactionTasks
> # we cancel all ongoing compactions
> # The CompactionTask created in #1 above registers itself in CompactionMetrics and misses that it should be cancelled
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)