CouchDB
  1. CouchDB
  2. COUCHDB-1137

add delete options for controlling file deletion

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 1.0.2
    • Fix Version/s: None
    • Component/s: Database Core
    • Labels:
      None
    • Skill Level:
      Regular Contributors Level (Easy to Medium)

      Description

      Even after switching to an extents-based filesystem I've noticed that deleting files after compaction can sometimes be terribly painful and slow. Additionally, deleting large pre-compact database and view files places extra load on the server that may be best kept to off hours. These sorts of large databases might be impossible to run a complete compact cycle on in short time. I'm suggesting we add an option to allow couch to leave files to be deleted in the .delete directories so administrators can delete them at their leisure (presumably at off hours or with a tool like ionice).

      1. delete_options.patch
        3 kB
        Randall Leeds
      2. respect_del_opts_on_db_init.patch
        2 kB
        Randall Leeds

        Activity

        Hide
        Randall Leeds added a comment -

        Patch add delete options. Currently just async and nodelete. nodelete might be a confusing name. I'm open to better suggestions.

        Show
        Randall Leeds added a comment - Patch add delete options. Currently just async and nodelete. nodelete might be a confusing name. I'm open to better suggestions.
        Hide
        Randall Leeds added a comment -

        One clause of couch_db_updater:init/1 was calling file:delete directly to remove old .compact files. I didn't see any reason for this so I unified the code and it will now respect the delete options patch here as a result.

        Show
        Randall Leeds added a comment - One clause of couch_db_updater:init/1 was calling file:delete directly to remove old .compact files. I didn't see any reason for this so I unified the code and it will now respect the delete options patch here as a result.
        Hide
        Randall Leeds added a comment -

        Tests forthcoming in separate patch.

        Show
        Randall Leeds added a comment - Tests forthcoming in separate patch.

          People

          • Assignee:
            Randall Leeds
            Reporter:
            Randall Leeds
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development