]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: fix drain handles error when deleting bucket with bypass-gc option 28789/head
authorDongdong Tao <dongdong.tao@canonical.com>
Sat, 29 Jun 2019 09:03:59 +0000 (17:03 +0800)
committertaodd <dongdong.tao@canonical.com>
Sat, 29 Jun 2019 09:42:00 +0000 (17:42 +0800)
Fixes: https://tracker.ceph.com/issues/40587
Signed-off-by: dongdong tao <dongdong.tao@canonical.com>
src/rgw/rgw_bucket.cc

index 8c78fdf10d5a8eec49c84745d25c96938ebcb52f..eacbb4938764e5ede9487ac835aae2f877adf16c 100644 (file)
@@ -694,7 +694,7 @@ int rgw_remove_bucket_bypass_gc(RGWRados *store, rgw_bucket& bucket,
         for (; miter != manifest.obj_end() && max_aio--; ++miter) {
           if (!max_aio) {
             ret = drain_handles(handles);
-            if (ret < 0) {
+            if (ret < 0 && ret != -ENOENT) {
               lderr(store->ctx()) << "ERROR: could not drain handles as aio completion returned with " << ret << dendl;
               return ret;
             }
@@ -723,7 +723,7 @@ int rgw_remove_bucket_bypass_gc(RGWRados *store, rgw_bucket& bucket,
 
       if (!max_aio) {
         ret = drain_handles(handles);
-        if (ret < 0) {
+        if (ret < 0 && ret != -ENOENT) {
           lderr(store->ctx()) << "ERROR: could not drain handles as aio completion returned with " << ret << dendl;
           return ret;
         }
@@ -733,7 +733,7 @@ int rgw_remove_bucket_bypass_gc(RGWRados *store, rgw_bucket& bucket,
   }
 
   ret = drain_handles(handles);
-  if (ret < 0) {
+  if (ret < 0 && ret != -ENOENT) {
     lderr(store->ctx()) << "ERROR: could not drain handles as aio completion returned with " << ret << dendl;
     return ret;
   }