From: Radoslaw Zarzynski Date: Mon, 9 Sep 2019 13:44:40 +0000 (+0200) Subject: crimson/osd: apply errorator along the read path, part 3. X-Git-Tag: v15.1.0~801^2~43 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=0d47d06b82bd11ca7582958d9f496f4a2d39e5f5;p=ceph-ci.git crimson/osd: apply errorator along the read path, part 3. Signed-off-by: Radoslaw Zarzynski --- diff --git a/src/crimson/common/errorator.h b/src/crimson/common/errorator.h index b3b7cddc575..155570e7188 100644 --- a/src/crimson/common/errorator.h +++ b/src/crimson/common/errorator.h @@ -11,7 +11,8 @@ namespace _impl { enum class ct_error { enoent, invarg, - enodata + enodata, + input_output_error }; } @@ -380,6 +381,7 @@ namespace ct_error { using enoent = unthrowable_wrapper<_impl::ct_error::enoent>; using enodata = unthrowable_wrapper<_impl::ct_error::enodata>; using invarg = unthrowable_wrapper<_impl::ct_error::invarg>; + using input_output_error = unthrowable_wrapper<_impl::ct_error::input_output_error>; } } // namespace crimson diff --git a/src/crimson/osd/pg_backend.h b/src/crimson/osd/pg_backend.h index 09d8ca165a1..4c26c568a7c 100644 --- a/src/crimson/osd/pg_backend.h +++ b/src/crimson/osd/pg_backend.h @@ -31,6 +31,8 @@ class PGBackend protected: using CollectionRef = crimson::os::CollectionRef; using ec_profile_t = std::map; + // low-level read errorator + using ll_read_errorator = crimson::os::FuturizedStore::read_errorator; public: PGBackend(shard_id_t shard, CollectionRef coll, crimson::os::FuturizedStore* store); @@ -44,6 +46,9 @@ public: using cached_os_t = boost::local_shared_ptr; seastar::future get_object_state(const hobject_t& oid); seastar::future<> evict_object_state(const hobject_t& oid); + + using read_errorator = \ + ll_read_errorator::extend; seastar::future read(const object_info_t& oi, uint64_t off, uint64_t len, @@ -110,8 +115,6 @@ public: virtual void got_rep_op_reply(const MOSDRepOpReply&) {} protected: - // low-level read errorator - using ll_read_errorator = ceph::os::FuturizedStore::read_errorator; const shard_id_t shard; CollectionRef coll; crimson::os::FuturizedStore* store;