]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
rgw: meta listing: adapt to new system
authorYehuda Sadeh <yehuda@redhat.com>
Thu, 9 May 2019 00:35:08 +0000 (17:35 -0700)
committerCasey Bodley <cbodley@redhat.com>
Mon, 29 Jul 2019 19:20:47 +0000 (15:20 -0400)
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
15 files changed:
src/rgw/rgw_bucket.cc
src/rgw/rgw_user.cc
src/rgw/services/svc_bucket.cc
src/rgw/services/svc_meta_be.cc
src/rgw/services/svc_meta_be.h
src/rgw/services/svc_meta_be_sobj.cc
src/rgw/services/svc_meta_be_sobj.h
src/rgw/services/svc_rados.cc
src/rgw/services/svc_rados.h
src/rgw/services/svc_sys_obj.cc
src/rgw/services/svc_sys_obj.h
src/rgw/services/svc_sys_obj_cache.h
src/rgw/services/svc_sys_obj_core.cc
src/rgw/services/svc_sys_obj_core.h
src/rgw/services/svc_user.cc

index a41f7ef2a8dfffb774ebfe50516a112f02ed8824..294bb35d703044c3d01f8610d74d3beee6d5a44a 100644 (file)
@@ -2360,17 +2360,6 @@ void RGWBucketCompleteInfo::decode_json(JSONObj *obj) {
   JSONDecoder::decode_json("attrs", attrs, obj);
 }
 
-class RGW_MB_Handler_Module_Bucket : public RGWSI_MBSObj_Handler_Module {
-  RGWSI_Zone *zone_svc;
-public:
-  RGW_MB_Handler_Module_Bucket(RGWSI_Zone *_zone_svc) : zone_svc(_zone_svc) {}
-
-  void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) override {
-    *oid = key;
-    *pool = zone_svc->get_zone_params().domain_root;
-  }
-};
-
 class RGWBucketMetadataHandler : public RGWMetadataHandler {
   RGWSI_MetaBackend_Handler *be_handler{nullptr};
 public:
index 1f2d39250919c42f594ed535525b4807503d978b..3b5e1e49843bfa5f0364ba39cd5cfd56ffc07afa 100644 (file)
@@ -2472,11 +2472,6 @@ public:
              optional_yield y,
              RGWMDLogSyncType type) override;
 
-  struct list_keys_info {
-    RGWRados *store;
-    RGWListRawObjsCtx ctx;
-  };
-
   int do_remove(RGWSI_MetaBackend_Handler::Op *op, string& entry, RGWObjVersionTracker& objv_tracker,
                 optional_yield y) {
     RGWUserInfo info;
@@ -2496,63 +2491,50 @@ public:
 
   int list_keys_init(const string& marker, void **phandle) override
   {
-    auto info = std::make_unique<list_keys_info>();
-
-    info->store = store;
+    std::unique_ptr<RGWSI_MetaBackend_Handler::Op> op(be_handler->alloc_op());
 
-    int ret = store->list_raw_objects_init(store->svc.zone->get_zone_params().user_uid_pool, marker,
-                                           &info->ctx);
+    int ret = op->list_init(marker);
     if (ret < 0) {
       return ret;
     }
 
-    *phandle = (void *)info.release();
+    *phandle = (void *)op.release();
 
     return 0;
   }
 
   int list_keys_next(void *handle, int max, list<string>& keys, bool *truncated) override {
-    list_keys_info *info = static_cast<list_keys_info *>(handle);
-
-    string no_filter;
-
-    keys.clear();
+    auto op = static_cast<RGWSI_MetaBackend_Handler::Op *>(handle);
 
-    RGWRados *store = info->store;
-
-    list<string> unfiltered_keys;
-
-    int ret = store->list_raw_objects_next(no_filter, max, info->ctx,
-                                           unfiltered_keys, truncated);
-    if (ret < 0 && ret != -ENOENT)
-      return ret;                      
+    int ret = op->list_next(max, &keys, truncated);
+    if (ret < 0 && ret != -ENOENT) {
+      return ret;
+    }
     if (ret == -ENOENT) {
-      if (truncated)
+      if (truncated) {
         *truncated = false;
-      return 0;
-    }
-
-    // now filter out the buckets entries
-    list<string>::iterator iter;
-    for (iter = unfiltered_keys.begin(); iter != unfiltered_keys.end(); ++iter) {
-      string& k = *iter;
-
-      if (k.find(".buckets") == string::npos) {
-        keys.push_back(k);
       }
+      return 0;
     }
 
     return 0;
   }
 
   void list_keys_complete(void *handle) override {
-    list_keys_info *info = static_cast<list_keys_info *>(handle);
-    delete info;
+    auto op = static_cast<RGWSI_MetaBackend_Handler::Op *>(handle);
+    delete op;
   }
 
   string get_marker(void *handle) override {
-    list_keys_info *info = static_cast<list_keys_info *>(handle);
-    return info->store->list_raw_objs_get_cursor(info->ctx);
+    auto op = static_cast<RGWSI_MetaBackend_Handler::Op *>(handle);
+    string marker;
+    int r = op->list_get_marker(&marker);
+    if (r < 0) {
+      lderr(svc.user->ctx(), 0) << "ERROR: " << __func__ << "(): list_get_marker() returned: r=" << r << dendl;
+      /* not much else to do */
+    }
+
+    return marker;
   }
 };
 
index 49eb0ad85f64c038a34023d4466f95537446d0bf..565ed9a9f6ff366cc4c35e78d58866229b214ea5 100644 (file)
 
 class RGWSI_Bucket_Module : public RGWSI_MBSObj_Handler_Module {
   RGWSI_Bucket::Svc& svc;
+
+  const string prefix;
 public:
   RGWSI_Bucket_Module(RGWSI_Bucket::Svc& _svc) : svc(_svc) {}
 
   void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) override {
-    *oid = key;
-    *pool = svc.zone->get_zone_params().domain_root;
+    if (pool) {
+      *pool = svc.zone->get_zone_params().domain_root;
+    }
+    if (oid) {
+      *oid = key;
+    }
+  }
+
+  const string& get_oid_prefix() override {
+    return prefix;
+  }
+
+  bool is_valid_oid(const string& oid) override {
+    return (!oid.empty() && oid[0] != '.');
+  }
+
+  string key_to_oid(const string& key) override {
+    return key;
+  }
+
+  string oid_to_key(const string& oid) override {
+    /* should have been called after is_valid_oid(),
+     * so no need to check for validity */
+    return oid;
   }
 };
 
 class RGWSI_BucketInstance_Module : public RGWSI_MBSObj_Handler_Module {
   RGWSI_Bucket::Svc& svc;
+
+  const string prefix;
 public:
-  RGWSI_BucketInstance_Module(RGWSI_Bucket::Svc& _svc) : svc(_svc) {}
+  RGWSI_BucketInstance_Module(RGWSI_Bucket::Svc& _svc) : svc(_svc), prefix(RGW_BUCKET_INSTANCE_MD_PREFIX) {}
 
-#warning get_hash_key?
-#if 0
-  /*
-   * hash entry for mdlog placement. Use the same hash key we'd have for the bucket entry
-   * point, so that the log entries end up at the same log shard, so that we process them
-   * in order
-   */
-  void get_hash_key(const string& section, const string& key, string& hash_key) override {
-    string k;
-    int pos = key.find(':');
-    if (pos < 0)
-      k = key;
-    else
-      k = key.substr(0, pos);
-    hash_key = "bucket:" + k;
+  void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) override {
+    if (pool) {
+      *pool = svc.zone->get_zone_params().domain_root;
+    }
+    if (oid) {
+      *oid = key_to_oid(key);
+    }
   }
-#endif
 
-  void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) override {
-    *oid = RGW_BUCKET_INSTANCE_MD_PREFIX + key;
-    *pool = svc.zone->get_zone_params().domain_root;
+  const string& get_oid_prefix() override {
+    return prefix;
+  }
+
+  bool is_valid_oid(const string& oid) override {
+    return (oid.compare(0, prefix.size(), RGW_BUCKET_INSTANCE_MD_PREFIX) == 0);
   }
 
 // 'tenant/' is used in bucket instance keys for sync to avoid parsing ambiguity
 // with the existing instance[:shard] format. once we parse the shard, the / is
 // replaced with a : to match the [tenant:]instance format
-  void key_to_oid(string& key) override {
+  string key_to_oid(const string& key) override {
+    string oid = prefix + key;
+
     // replace tenant/ with tenant:
-    auto c = key.find('/');
+    auto c = oid.find('/', prefix.size());
     if (c != string::npos) {
-      key[c] = ':';
+      oid[c] = ':';
     }
+
+    return oid;
   }
 
   // convert bucket instance oids back to the tenant/ format for metadata keys.
   // it's safe to parse 'tenant:' only for oids, because they won't contain the
   // optional :shard at the end
-  void oid_to_key(string& oid) override {
+  string oid_to_key(const string& oid) override {
+    /* this should have been called after oid was checked for validity */
+
+    if (oid.size() < prefix.size()) { /* just sanity check */
+      return string();
+    }
+
+    string key = oid.substr(prefix.size());
+
     // find first : (could be tenant:bucket or bucket:instance)
-    auto c = oid.find(':');
+    auto c = key.find(':');
     if (c != string::npos) {
       // if we find another :, the first one was for tenant
-      if (oid.find(':', c + 1) != string::npos) {
-        oid[c] = '/';
+      if (key.find(':', c + 1) != string::npos) {
+        key[c] = '/';
       }
     }
+
+    return key;
+  }
+
+  /*
+   * hash entry for mdlog placement. Use the same hash key we'd have for the bucket entry
+   * point, so that the log entries end up at the same log shard, so that we process them
+   * in order
+   */
+  string get_hash_key(const string& section, const string& key) override {
+    string k = "bucket:";
+    int pos = key.find(':');
+    if (pos < 0)
+      k.append(key);
+    else
+      k.append(key.substr(0, pos));
+
+    return k;
   }
 };
 
index 7093c46f7796cf9411d2d6970bebc3fc70065fc8..3bbf9477667d33c5462d850a193d554e78941edc 100644 (file)
@@ -183,3 +183,13 @@ int RGWSI_MetaBackend_Handler::call(std::function<int(Op *)> f)
   });
 }
 
+RGWSI_MetaBackend_Handler::Op *RGWSI_MetaBackend_Handler::alloc_op()
+{
+  return new Op_ManagedCtx(be);
+}
+
+RGWSI_MetaBackend_Handler::Op_ManagedCtx::Op_ManagedCtx(RGWSI_MetaBackend *_be) : Op(_be, _be->alloc_ctx())
+{
+  pctx.reset(ctx());
+}
+
index 87daded3940395f0386f936b83cba4b267fe35f3..38306bc8c4122cbf8fc5631e76fc5555d28afb91 100644 (file)
@@ -84,6 +84,8 @@ public:
     virtual void init(RGWSI_MetaBackend_Handler *h) = 0;
   };
 
+  virtual Context *alloc_ctx() = 0;
+
   struct PutParams {
     ceph::real_time mtime;
 
@@ -136,9 +138,12 @@ public:
                            RGWObjVersionTracker *objv_tracker,
                            optional_yield y) = 0;
 
-  virtual int list_init(const string& marker, void **phandle) = 0;
-  virtual int list_next(void *handle, int max, std:::list<std::string>& keys, bool *truncated) = 0;
-  virtual void list_complete(void *handle) = 0;
+  virtual int list_init(RGWSI_MetaBackend::Context *ctx, const string& marker) = 0;
+  virtual int list_next(RGWSI_MetaBackend::Context *ctx,
+                        int max, list<string>& keys,
+                        bool *truncated)  = 0;
+  virtual int list_get_marker(RGWSI_MetaBackend::Context *ctx,
+                              string *marker) = 0;
 
   virtual int call(std::function<int(RGWSI_MetaBackend::Context *)> f) = 0;
 
@@ -202,11 +207,29 @@ public:
                RGWMDLogSyncType sync_mode) {
       return be->remove(be_ctx, key, params, objv_tracker, sync_mode);
     }
+
+    int list_init(const string& marker) {
+      return be->list_init(be_ctx, marker);
+    }
+    int list_next(int max, list<string>& keys,
+                  bool *truncated) {
+      return be->list_next(max, keys, truncated);
+    }
+    int list_get_marker(string *marker) {
+      return be->list_get_marker(marker);
+    }
+  };
+
+  class Op_ManagedCtx : public Op {
+    std::unique_ptr<RGWSI_MetaBackend::Context> pctx;
+  public:
+    Op_ManagedCtx(RGWSI_MetaBackend *_be);
   };
 
   RGWSI_MetaBackend_Handler(RGWSI_MetaBackend *_be) : be(_be) {}
   virtual ~RGWSI_MetaBackend_Handler() {}
 
   virtual int call(std::function<int(Op *)> f);
+  virtual Op *alloc_op();
 };
 
index 06aee3aab7e3ebfadc6bb39ccd9cfd1ef454818b..5e43beeab8c97f7a2a495cfe2e1d6798b5e76139 100644 (file)
@@ -19,6 +19,11 @@ RGWSI_MetaBackend_Handler *RGWSI_MetaBackend_SObj::alloc_be_handler()
   return new RGWSI_MetaBackend_Handler_SObj(this);
 }
 
+RGWSI_MetaBackend_SObj::alloc_ctx()
+{
+  return new ctx(sysobj_svc);
+}
+
 int RGWSI_MetaBackend_SObj::call(std::function<int(RGWSI_MetaBackend::Context *)> f)
 {
   RGWSI_MetaBackend_SObj::Context_SObj ctx(sysobj_svc);
@@ -94,30 +99,34 @@ int RGWSI_MetaBackend_SObj::remove_entry(RGWSI_MetaBackend::Context *_ctx,
                .remove(params.y);
 }
 
-int RGWSI_MetaBackend_SObj::list_init(const string& marker, void **phandle) override {
-    auto info = std::make_unique<list_keys_info>();
+int RGWSI_MetaBackend_SObj::list_init(RGWSI_MetaBackend::Context *_ctx,
+                                      const string& marker)
+{
+  RGWSI_MetaBackend_SObj::Context_SObj *ctx = static_cast<RGWSI_MetaBackend_SObj::Context_SObj *>(_ctx);
 
-    int ret = store->list_raw_objects_init(store->svc.zone->get_zone_params().domain_root, marker,
-                                           &info->ctx);
-    if (ret < 0) {
-      return ret;
-    }
-    *phandle = (void *)info.release();
+  rgw_pool pool;
 
-    return 0;
-  }
+  string no_key;
+  ctx->module->get_pool_and_oid(no_key, &ctx->list.pool, nullptr);
 
-int RGWSI_MetaBackend_SObj::list_next(void *handle, int max, list<string>& keys, bool *truncated) override {
-  list_keys_info *info = static_cast<list_keys_info *>(handle);
+  ctx->list.pool = sysobj_svc->get_pool(pool);
+  ctx->list.op = ctx->list.pool->op();
 
-  string no_filter;
+  string prefix = ctx->module->get_prefix();
+  ctx->list.op->init(marker, prefix);
 
-  keys.clear();
+  return 0;
+}
+
+int RGWSI_MetaBackend_SObj::list_next(RGWSI_MetaBackend::Context *_ctx,
+                                      int max, list<string>& keys,
+                                      bool *truncated)
+{
+  RGWSI_MetaBackend_SObj::Context_SObj *ctx = static_cast<RGWSI_MetaBackend_SObj::Context_SObj *>(_ctx);
 
-  list<string> unfiltered_keys;
+  vector<string> oids;
 
-  int ret = store->list_raw_objects_next(no_filter, max, info->ctx,
-                                         unfiltered_keys, truncated);
+  int ret = ctx->list.op->get_next(max, &oids, truncated);
   if (ret < 0 && ret != -ENOENT)
     return ret;
   if (ret == -ENOENT) {
@@ -126,29 +135,23 @@ int RGWSI_MetaBackend_SObj::list_next(void *handle, int max, list<string>& keys,
     return 0;
   }
 
-  constexpr int prefix_size = sizeof(RGW_BUCKET_INSTANCE_MD_PREFIX) - 1;
-  // now filter in the relevant entries
-  list<string>::iterator iter;
-  for (iter = unfiltered_keys.begin(); iter != unfiltered_keys.end(); ++iter) {
-    string& k = *iter;
+  auto module = ctx->module;
 
-    if (k.compare(0, prefix_size, RGW_BUCKET_INSTANCE_MD_PREFIX) == 0) {
-      auto oid = k.substr(prefix_size);
-      rgw_bucket_instance_oid_to_key(oid);
-      keys.emplace_back(std::move(oid));
+  for (auto& o : oids) {
+    if (!module->is_valid_oid(o)) {
+      continue;
     }
+    keys.emplace_back(module->oid_to_key(o));
   }
 
   return 0;
 }
 
-void RGWSI_MetaBackend_SObj::list_complete(void *handle) override {
-  list_keys_info *info = static_cast<list_keys_info *>(handle);
-  delete info;
-}
+int RGWSI_MetaBackend_SObj::list_get_marker(RGWSI_MetaBackend::Context *_ctx,
+                                            string *marker)
+{
+  RGWSI_MetaBackend_SObj::Context_SObj *ctx = static_cast<RGWSI_MetaBackend_SObj::Context_SObj *>(_ctx);
 
-string get_marker(void *handle) override {
-  list_keys_info *info = static_cast<list_keys_info *>(handle);
-  return info->store->list_raw_objs_get_cursor(info->ctx);
+  return ctx->list.op->get_marker(marker);
 }
 
index 35cfe9e559d1c0296f31a37aaddb5af3b9616b75..ca788c545a593e7780790b47551f1ac356b3aece 100644 (file)
 
 class RGWSI_MBSObj_Handler_Module : public RGWSI_MetaBackend::Module {
 public:
-  virtual void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) = 0;
-  virtual void key_to_oid(string& key) {}
-  virtual void oid_to_key(string& oid) {}
+  virtual void get_pool_and_oid(const std::string& key, rgw_pool *pool, std::string *oid) = 0;
+  virtual const std::string& get_oid_prefix() = 0;
+  virtual std::string key_to_oid(const std::string& key) = 0;
+  virtual bool is_valid_oid(const std::string& oid) = 0;
+  virtual std::string oid_to_key(const std::string& oid) = 0;
 
   /* key to use for hashing entries for log shard placement */
-  virtual void get_hash_key(const std::string& section, const std::string& key, std::string& hash_key) {
-    hash_key = section + ":" + key;
+  virtual std::string get_hash_key(const std::string& section, const std::string& key) {
+    return section + ":" + key;
   }
 };
 
@@ -91,7 +93,11 @@ public:
     RGWSI_SysObj *sysobj_svc{nullptr};
 
     RGWSI_MBSObj_Handler_Module *module{nullptr};
-    optional<RGWSysObjectCtx> obj_ctx;
+    std::optional<RGWSysObjectCtx> obj_ctx;
+    struct _list {
+      std::optional<RGWSI_SysObj::Pool> pool;
+      std::optional<RGWSI_SysObj::Pool::Op> op;
+    } list;
 
     Context_SObj(RGWSI_SysObj *_sysobj_svc) : sysobj_svc(_sysobj_svc) {}
 
@@ -128,9 +134,12 @@ public:
                    RGWSI_MetaBackend::RemoveParams& params,
                    RGWObjVersionTracker *objv_tracker) override;
 
-  int list_init(const string& marker, void **phandle) override;
-  int list_next(void *handle, int max, std:::list<std::string>& keys, bool *truncated) override;
-  void list_complete(void *handle) override;
+  int list_init(RGWSI_MetaBackend::Context *_ctx, const string& marker) override;
+  int list_next(RGWSI_MetaBackend::Context *_ctx,
+                int max, list<string>& keys,
+                bool *truncated) override;
+  int list_get_marker(RGWSI_MetaBackend::Context *ctx,
+                      string *marker) override;
 
   int call(std::function<int(RGWSI_MetaBackend::Context *)> f) override;
 };
index e5c61bd7493c8c497a510d835a2ec2752b5296d9..d32a5ee72b1aac2317d1fa1a83854de409681ab2 100644 (file)
@@ -311,3 +311,13 @@ int RGWSI_RADOS::Handle::watch_flush()
   librados::Rados *rad = rados_svc->get_rados_handle();
   return rad->watch_flush();
 }
+
+int RGWSI_RADOS::Pool::List::get_marker(string *marker)
+{
+  if (!ctx.initialized) {
+    return -EINVAL;
+  }
+
+  *marker = ctx.iter.get_cursor().to_str();
+  return 0;
+}
index 338d122a66bde8a3c4e1244f3d62b913e5d7952a..30babd79c97494afc3cc2519769a9b6a06439bf1 100644 (file)
@@ -134,6 +134,8 @@ public:
       int get_next(int max,
                    std::vector<string> *oids,
                    bool *is_truncated);
+
+      int get_marker(string *marker);
     };
 
     List op() {
index ddd2d5647266fde65776e532ca44843f13ab20b2..b023f37cc088d83f1f03bccd85d6035ff4068948 100644 (file)
@@ -126,6 +126,11 @@ int RGWSI_SysObj::Pool::Op::get_next(int max, vector<string> *oids, bool *is_tru
   return source.core_svc->pool_list_objects_next(ctx, max, oids, is_truncated);
 }
 
+int RGWSI_SysObj::Pool::Op::get_marker(string *marker)
+{
+  return source.core_svc->pool_list_objects_get_marker(ctx, marker);
+}
+
 int RGWSI_SysObj::Obj::OmapOp::get_all(std::map<string, bufferlist> *m,
                                        optional_yield y)
 {
index a4130814b9f29705b60c8a09d591d882acf33b5e..70f96d9fd803fd5a3aefcf32b1b42c8f26800e20 100644 (file)
@@ -232,6 +232,7 @@ public:
 
       int init(const std::string& marker, const std::string& prefix);
       int get_next(int max, std::vector<string> *oids, bool *is_truncated);
+      int get_marker(string *marker);
     };
 
     int list_prefixed_objs(const std::string& prefix, std::vector<std::string> *result);
index 4c491c1bec7aa680dffc7610aa06ffac078abbd7..62350736ce83a20eb87c99632495626982f69860 100644 (file)
@@ -42,7 +42,7 @@ protected:
                optional_yield y) override;
 
   int read(RGWSysObjectCtxBase& obj_ctx,
-           GetObjState& read_state,
+           RGWSI_SysObj_Obj_GetObjState& read_state,
            RGWObjVersionTracker *objv_tracker,
            const rgw_raw_obj& obj,
            bufferlist *bl, off_t ofs, off_t end,
index b037c906b3b3c2454178a19214a35351585d442c..901f50a44c7554c342d75d11e8c89603fa4fccf4 100644 (file)
@@ -694,3 +694,13 @@ int RGWSI_SysObj_Core::pool_list_objects_next(RGWSI_SysObj::Pool::ListCtx& _ctx,
   return oids->size();
 }
 
+int RGWSI_SysObj_Core::pool_list_objects_get_marker(RGWSI_SysObj::Pool::ListCtx& _ctx,
+                                                    string *marker)
+{
+  if (!_ctx.impl) {
+    return -EINVAL;
+  }
+
+  auto& ctx = static_cast<PoolListImplInfo&>(*_ctx.impl);
+  return ctx.op.get_marker(marker);
+}
index 7c879f3fd3c16c7e93edea3c6cb34d6e47fe4af2..6391f75c30a66b41b154e857e29b81100c4f81a4 100644 (file)
@@ -112,6 +112,9 @@ protected:
                                      vector<string> *oids,
                                      bool *is_truncated);
 
+  virtual int pool_list_objects_get_marker(RGWSI_SysObj::Pool::ListCtx& _ctx,
+                                           string *marker);
+
   /* wrappers */
   int get_system_obj_state_impl(RGWSysObjectCtxBase *rctx,
                                 const rgw_raw_obj& obj, RGWSysObjState **state,
index 2697c83af8d64b40339ff37fe676b2b98de54891..edb01452c4eeeae53e25401b906d867eb465f2ba 100644 (file)
 
 class RGWSI_User_Module : public RGWSI_MBSObj_Handler_Module {
   RGWSI_User::Svc& svc;
+
+  const string prefix;
 public:
   RGWSI_User_Module(RGWSI_User::Svc& _svc) : svc(_svc) {}
 
   void get_pool_and_oid(const string& key, rgw_pool *pool, string *oid) override {
-    *oid = key;
-    *pool = svc.zone->get_zone_params().user_uid_pool;
+    if (pool) {
+      *pool = svc.zone->get_zone_params().user_uid_pool;
+    }
+    if (oid) {
+      *oid = key;
+    }
+  }
+
+  const string& get_oid_prefix() override {
+    return prefix;
+  }
+
+  bool is_valid_oid(const string& oid) override {
+    return true;
+  }
+
+  string key_to_oid(const string& key) override {
+    return key;
+  }
+
+  string oid_to_key(const string& oid) override {
+    return oid;
   }
 };