]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/rgw/rgw_cache.cc
import 15.2.5
[ceph.git] / ceph / src / rgw / rgw_cache.cc
index 41dd004c10f8959687fe4be024eece07c97e3b32..90a608d1bf159d6e1018c941a14463245af30600 100644 (file)
@@ -67,6 +67,11 @@ int ObjectCache::get(const string& name, ObjectCacheInfo& info, uint32_t mask, r
   }
 
   ObjectCacheInfo& src = iter->second.info;
+  if(src.status == -ENOENT) {
+    ldout(cct, 10) << "cache get: name=" << name << " : hit (negative entry)" << dendl;
+    if (perfcounter) perfcounter->inc(l_rgw_cache_hit);
+    return -ENODATA;
+  }
   if ((src.flags & mask) != mask) {
     ldout(cct, 10) << "cache get: name=" << name << " : type miss (requested=0x"
                    << std::hex << mask << ", cached=0x" << src.flags