]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
OSD: no need to remove snapdirs on _remove_pg()
authorSamuel Just <sam.just@inktank.com>
Mon, 29 Apr 2013 16:03:12 +0000 (09:03 -0700)
committerSamuel Just <sam.just@inktank.com>
Mon, 29 Apr 2013 22:56:19 +0000 (15:56 -0700)
The snapmapper patches removed snapdirs altogether.

Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osd/OSD.cc

index dc05415dbd4644b04e1036c07ef2674f5521771c..f5571c6f5dbab7e8e3718a3355a4f8ce30b12f9d 100644 (file)
@@ -5834,17 +5834,6 @@ void OSD::_remove_pg(PG *pg)
 {
   vector<coll_t> removals;
   ObjectStore::Transaction *rmt = new ObjectStore::Transaction;
-  for (interval_set<snapid_t>::iterator p = pg->snap_collections.begin();
-       p != pg->snap_collections.end();
-       ++p) {
-    for (snapid_t cur = p.get_start();
-        cur < p.get_start() + p.get_len();
-        ++cur) {
-      coll_t to_remove = get_next_removal_coll(pg->info.pgid);
-      removals.push_back(to_remove);
-      rmt->collection_rename(coll_t(pg->info.pgid, cur), to_remove);
-    }
-  }
   coll_t to_remove = get_next_removal_coll(pg->info.pgid);
   removals.push_back(to_remove);
   rmt->collection_rename(coll_t(pg->info.pgid), to_remove);