Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch/pull/161#issuecomment-209525568
  
    @eiri the first PR comment says 'This change makes compaction files to stay 
in .deleted directory in case config parameter rename_on_delete is set and 
renames them in fashion, that makes it easier to restore them if necessary. ' 
but what you've done is rename-then-delete which does not achieve the goal.
    
    I think rename_on_delete might be a misleading name. 
rename_instead_of_delete is the meaning. Wherever we delete a file, whether 
that's a database or view compaction that completes or a user deletes a 
database, we want one of two behaviours: 1) we delete the file immediately 
(yes, we'll mv it to the .delete directory first so that we can clean up easily 
in the event of a crash, but that's normal couchdb behaviour) or 2) we rename 
the file (appending a unique timestamp or similar) and do not delete it, so 
that it can be recovered. Anyone that sets this config flag is then required to 
find and delete these files later if they don't intend to restore them (so a 
useful pattern like *.deleted.couch / *.deleted.view is warranted).
    
    Have I misunderstood the scope of this pull request?



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to