You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Ran Tavory (JIRA)" <ji...@apache.org> on 2010/02/09 13:28:28 UTC

[jira] Created: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Create a cleanup utility that cleans all data directories
---------------------------------------------------------

                 Key: CASSANDRA-782
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
             Project: Cassandra
          Issue Type: New Feature
          Components: Contrib
    Affects Versions: 0.6
            Reporter: Ran Tavory
            Assignee: Ran Tavory
            Priority: Minor


A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:

1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
3. Test runs... adds data to cassandra, reads, deletes etc.
4. Test stops the embedded cassandra service
5. Test cleans up all data to leave the file system clean.


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


[jira] Commented: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Gary Dusbabek (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12832531#action_12832531 ] 

Gary Dusbabek commented on CASSANDRA-782:
-----------------------------------------

Two more things and I think we're done.  First, I think that `ant clean` should also delete ${test.reports}.  Second, would you consider renaming CassandraServiceDataCleanerTest to CassandraServiceTest?  The reason being that it doesn't really test any of the functionality in CassandraServiceDataCleaner.  (Or you could keep it named the same and add some tests to verify that CassandraServiceDataCleaner does what it claims to do.)

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Commented: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Gary Dusbabek (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12833099#action_12833099 ] 

Gary Dusbabek commented on CASSANDRA-782:
-----------------------------------------

+1

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Commented: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Ran Tavory (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12832102#action_12832102 ] 

Ran Tavory commented on CASSANDRA-782:
--------------------------------------

Hi Gary, I agree method names were a little confusing and functionality not clear, so I renamed rmdir() to cleanDir() and changed it's functionality to not delete the directory, but only the directory content (files in it)

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Updated: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Ran Tavory (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ran Tavory updated CASSANDRA-782:
---------------------------------

    Attachment: CASSANDRA-782.patch

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Commented: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12834883#action_12834883 ] 

Hudson commented on CASSANDRA-782:
----------------------------------

Integrated in Cassandra #357 (See [http://hudson.zones.apache.org/hudson/job/Cassandra/357/])
    

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>             Fix For: 0.6
>
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Commented: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Gary Dusbabek (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12832030#action_12832030 ] 

Gary Dusbabek commented on CASSANDRA-782:
-----------------------------------------

The docs for prepare() indicate that it is supposed to create the data dirs, but it seems that the last method call removes them.  Should the two method calls be switched?  

In practice, this won't matter much because the SSTable code does a good job of making directories where they don't already exist.

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Updated: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Ran Tavory (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ran Tavory updated CASSANDRA-782:
---------------------------------

    Attachment: CASSANDRA-782.patch

Applied latest comments from Gary:
1. Rename CassandraServiceDataCleanerTest => CassandraServiceTest
2. Cleanup reports directory with ant clean


> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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


[jira] Updated: (CASSANDRA-782) Create a cleanup utility that cleans all data directories

Posted by "Ran Tavory (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-782?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ran Tavory updated CASSANDRA-782:
---------------------------------

    Attachment: CASSANDRA-782.patch

Renamed rmdir() to cleanDir() and changed it's functionality to not delete the directory, but only the directory content (files in it)

> Create a cleanup utility that cleans all data directories
> ---------------------------------------------------------
>
>                 Key: CASSANDRA-782
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-782
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Contrib
>    Affects Versions: 0.6
>            Reporter: Ran Tavory
>            Assignee: Ran Tavory
>            Priority: Minor
>         Attachments: CASSANDRA-782.patch, CASSANDRA-782.patch
>
>
> A cleanup utility is useful for tests, unit tests of products that use cassandra as a blackbox.
> A cleanup utility may be used in conjunction with an embedded cassandra service (see CASSANDRA-740) in the following way:
> 1. Test starts by creating the data directories, if they don't exist, and deleting all content in them to make sure there's a fresh clean start (all this provided by this improvement)
> 2. Test starts an embedded cassandra service (provided by CASSANDRA-740).
> 3. Test runs... adds data to cassandra, reads, deletes etc.
> 4. Test stops the embedded cassandra service
> 5. Test cleans up all data to leave the file system clean.

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