Uploaded image for project: 'PHP Driver: Library'
  1. PHP Driver: Library
  2. PHPLIB-55

Ensure GridFS removal doesn't leave orphan chunks behind

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 0.1.0
    • Component/s: None
    • Labels:
      None

      PHP-1228 describes an edge case with the 1.x driver's method for removing files:

      Because this isn't a transaction, it is possible that a new file gets inserted while another process is in the middle of MongoGridFS::remove(). And if that new file happens to match the removal criteria, we could end up deleting its fs.files document and leaving its chunks behind. That said, it looks like you were only removing fs.files documents in your OP, so I don't think this would be an issue.

            Assignee:
            jmikola@mongodb.com Jeremy Mikola
            Reporter:
            jmikola@mongodb.com Jeremy Mikola
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: