cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Bohm (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CASSANDRA-983) flush and snapshot keyspace/CF before dropping it
Date Fri, 07 May 2010 13:16:49 GMT

    [ https://issues.apache.org/jira/browse/CASSANDRA-983?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12865141#action_12865141
] 

Paul Bohm commented on CASSANDRA-983:
-------------------------------------

Not within a CF but within a KS directory. We keep snapshots in "tableName/snapshots/":

    public static String getSnapshotPath(String dataDirPath, String tableName, String snapshotName)
    {
        return dataDirPath + File.separator + tableName + File.separator + SNAPSHOT_SUBDIR_NAME
+ File.separator + snapshotName;
    }

Since we now flush/snapshot before dropping a KS, you get the snapshots directory there for
free. The patch prevents cassandra from unsuccessfully trying to parse 'snapshots' as CF filename
- e.g. when you later try to create a new KS by the same name.

I considered checking for filename == SNAPSHOT_SUBDIR_NAME specifically, but decided against
it. Directories cannot be CFs and attempting to parse their name as CF makes no sense.

> flush and snapshot keyspace/CF before dropping it
> -------------------------------------------------
>
>                 Key: CASSANDRA-983
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-983
>             Project: Cassandra
>          Issue Type: New Feature
>    Affects Versions: 0.7
>            Reporter: Jonathan Ellis
>            Assignee: Jonathan Ellis
>            Priority: Minor
>             Fix For: 0.7
>
>         Attachments: 983-2.txt, 983.txt, snapshot_parsing_fix.patch
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message