}
int MemStore::getattrs(CollectionHandle &c_, const ghobject_t& oid,
- std::map<std::string,ceph::buffer::ptr>& aset)
+ std::map<std::string,ceph::buffer::ptr,std::less<>>& aset)
{
Collection *c = static_cast<Collection*>(c_.get());
dout(10) << __func__ << " " << c->cid << " " << oid << dendl;
return 0;
}
+#ifdef WITH_SEASTAR
+int MemStore::omap_get_values(
+ CollectionHandle& ch, ///< [in] Collection containing oid
+ const ghobject_t &oid, ///< [in] Object containing omap
+ const std::optional<std::string> &start_after, ///< [in] Keys to get
+ std::map<std::string, ceph::buffer::list> *out ///< [out] Returned keys and values
+ )
+{
+ dout(10) << __func__ << " " << ch->cid << " " << oid << dendl;
+ Collection *c = static_cast<Collection*>(ch.get());
+ ObjectRef o = c->get_object(oid);
+ if (!o)
+ return -ENOENT;
+ assert(start_after);
+ std::lock_guard lock{o->omap_mutex};
+ for (auto it = o->omap.upper_bound(*start_after);
+ it != std::end(o->omap);
+ ++it) {
+ out->insert(*it);
+ }
+ return 0;
+}
+#endif
+
int MemStore::omap_check_keys(
CollectionHandle& ch, ///< [in] Collection containing oid
const ghobject_t &oid, ///< [in] Object containing omap