diff options
Diffstat (limited to 'src/rgw')
-rw-r--r-- | src/rgw/rgw_auth.h | 14 | ||||
-rw-r--r-- | src/rgw/rgw_auth_filters.h | 26 | ||||
-rw-r--r-- | src/rgw/rgw_auth_registry.h | 20 | ||||
-rw-r--r-- | src/rgw/rgw_auth_s3.h | 42 | ||||
-rw-r--r-- | src/rgw/rgw_cr_tools.cc | 2 | ||||
-rw-r--r-- | src/rgw/rgw_op.h | 13 | ||||
-rw-r--r-- | src/rgw/rgw_rados.h | 3 | ||||
-rw-r--r-- | src/rgw/rgw_rest.cc | 2 | ||||
-rw-r--r-- | src/rgw/rgw_rest_s3.cc | 8 | ||||
-rw-r--r-- | src/rgw/rgw_rest_s3.h | 26 | ||||
-rw-r--r-- | src/rgw/rgw_rest_sts.h | 10 | ||||
-rw-r--r-- | src/rgw/rgw_role.cc | 56 | ||||
-rw-r--r-- | src/rgw/rgw_role.h | 20 | ||||
-rw-r--r-- | src/rgw/rgw_service.cc | 28 | ||||
-rw-r--r-- | src/rgw/rgw_service.h | 5 | ||||
-rw-r--r-- | src/rgw/rgw_swift_auth.h | 42 | ||||
-rw-r--r-- | src/rgw/rgw_tools.cc | 4 | ||||
-rw-r--r-- | src/rgw/rgw_tools.h | 4 | ||||
-rw-r--r-- | src/rgw/rgw_trim_mdlog.cc | 2 | ||||
-rw-r--r-- | src/rgw/services/svc_bi.h | 3 | ||||
-rw-r--r-- | src/rgw/services/svc_bi_rados.h | 2 |
21 files changed, 178 insertions, 154 deletions
diff --git a/src/rgw/rgw_auth.h b/src/rgw/rgw_auth.h index 8f15d096543..f6ee0e7843c 100644 --- a/src/rgw/rgw_auth.h +++ b/src/rgw/rgw_auth.h @@ -16,7 +16,7 @@ #define RGW_USER_ANON_ID "anonymous" -class RGWUserCtl; +class RGWCtl; namespace rgw { namespace auth { @@ -355,17 +355,17 @@ class StrategyRegistry; class WebIdentityApplier : public IdentityApplier { protected: CephContext* const cct; - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; rgw::web_idp::WebTokenClaims token_claims; string get_idp_url() const; public: WebIdentityApplier( CephContext* const cct, - RGWUserCtl* const user_ctl, + RGWCtl* const ctl, const rgw::web_idp::WebTokenClaims& token_claims) : cct(cct), - user_ctl(user_ctl), + ctl(ctl), token_claims(token_claims) { } @@ -457,7 +457,7 @@ protected: CephContext* const cct; /* Read-write is intensional here due to RGWUserInfo creation process. */ - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; /* Supplemental strategy for extracting permissions from ACLs. Its results * will be combined (ORed) with a default strategy that is responsible for @@ -473,12 +473,12 @@ protected: public: RemoteApplier(CephContext* const cct, - RGWUserCtl* const user_ctl, + RGWCtl* const ctl, acl_strategy_t&& extra_acl_strategy, const AuthInfo& info, const bool implicit_tenants) : cct(cct), - user_ctl(user_ctl), + ctl(ctl), extra_acl_strategy(std::move(extra_acl_strategy)), info(info), implicit_tenants(implicit_tenants) { diff --git a/src/rgw/rgw_auth_filters.h b/src/rgw/rgw_auth_filters.h index 676379f13f8..7c3a1a6dca3 100644 --- a/src/rgw/rgw_auth_filters.h +++ b/src/rgw/rgw_auth_filters.h @@ -109,7 +109,7 @@ public: template <typename T> class ThirdPartyAccountApplier : public DecoratedApplier<T> { - /* const */RGWUserCtl* const user_ctl; + /* const */RGWCtl* const ctl; const rgw_user acct_user_override; public: @@ -119,11 +119,11 @@ public: static const rgw_user UNKNOWN_ACCT; template <typename U> - ThirdPartyAccountApplier(RGWUserCtl* const user_ctl, + ThirdPartyAccountApplier(RGWCtl* const ctl, const rgw_user &acct_user_override, U&& decoratee) : DecoratedApplier<T>(std::move(decoratee)), - user_ctl(user_ctl), + ctl(ctl), acct_user_override(acct_user_override) { } @@ -161,13 +161,13 @@ void ThirdPartyAccountApplier<T>::load_acct_info(const DoutPrefixProvider* dpp, if (acct_user_override.tenant.empty()) { const rgw_user tenanted_uid(acct_user_override.id, acct_user_override.id); - if (user_ctl->get_info_by_uid(tenanted_uid, &user_info) >= 0) { + if (ctl->user->get_info_by_uid(tenanted_uid, &user_info) >= 0) { /* Succeeded. */ return; } } - const int ret = user_ctl->get_info_by_uid(acct_user_override, &user_info); + const int ret = ctl->user->get_info_by_uid(acct_user_override, &user_info); if (ret < 0) { /* We aren't trying to recover from ENOENT here. It's supposed that creating * someone else's account isn't a thing we want to support in this filter. */ @@ -182,10 +182,10 @@ void ThirdPartyAccountApplier<T>::load_acct_info(const DoutPrefixProvider* dpp, } template <typename T> static inline -ThirdPartyAccountApplier<T> add_3rdparty(RGWUserCtl* const user_ctl, +ThirdPartyAccountApplier<T> add_3rdparty(RGWCtl* const ctl, const rgw_user &acct_user_override, T&& t) { - return ThirdPartyAccountApplier<T>(user_ctl, acct_user_override, + return ThirdPartyAccountApplier<T>(ctl, acct_user_override, std::forward<T>(t)); } @@ -193,19 +193,19 @@ ThirdPartyAccountApplier<T> add_3rdparty(RGWUserCtl* const user_ctl, template <typename T> class SysReqApplier : public DecoratedApplier<T> { CephContext* const cct; - /*const*/ RGWUserCtl* const user_ctl; + /*const*/ RGWCtl* const ctl; const RGWHTTPArgs& args; mutable boost::tribool is_system; public: template <typename U> SysReqApplier(CephContext* const cct, - /*const*/ RGWUserCtl* const user_ctl, + /*const*/ RGWCtl* const ctl, const req_state* const s, U&& decoratee) : DecoratedApplier<T>(std::forward<T>(decoratee)), cct(cct), - user_ctl(user_ctl), + ctl(ctl), args(s->info.args), is_system(boost::logic::indeterminate) { } @@ -237,7 +237,7 @@ void SysReqApplier<T>::load_acct_info(const DoutPrefixProvider* dpp, RGWUserInfo * reasons. rgw_get_user_info_by_uid doesn't trigger the operator=() but * calls ::decode instead. */ RGWUserInfo euser_info; - if (user_ctl->get_info_by_uid(effective_uid, &euser_info) < 0) { + if (ctl->user->get_info_by_uid(effective_uid, &euser_info) < 0) { //ldpp_dout(dpp, 0) << "User lookup failed!" << dendl; throw -EACCES; } @@ -263,10 +263,10 @@ void SysReqApplier<T>::modify_request_state(const DoutPrefixProvider* dpp, req_s template <typename T> static inline SysReqApplier<T> add_sysreq(CephContext* const cct, - /* const */ RGWUserCtl* const user_ctl, + /* const */ RGWCtl* const ctl, const req_state* const s, T&& t) { - return SysReqApplier<T>(cct, user_ctl, s, std::forward<T>(t)); + return SysReqApplier<T>(cct, ctl, s, std::forward<T>(t)); } } /* namespace auth */ diff --git a/src/rgw/rgw_auth_registry.h b/src/rgw/rgw_auth_registry.h index 9316e8ec4eb..a5aed976253 100644 --- a/src/rgw/rgw_auth_registry.h +++ b/src/rgw/rgw_auth_registry.h @@ -36,9 +36,9 @@ class StrategyRegistry { s3_main_strategy_plain_t s3_main_strategy_plain; s3_main_strategy_boto2_t s3_main_strategy_boto2; - s3_main_strategy_t(CephContext* const cct, RGWRados* const store) - : s3_main_strategy_plain(cct, store), - s3_main_strategy_boto2(cct, store) { + s3_main_strategy_t(CephContext* const cct, RGWCtl* const ctl) + : s3_main_strategy_plain(cct, ctl), + s3_main_strategy_boto2(cct, ctl) { add_engine(Strategy::Control::SUFFICIENT, s3_main_strategy_plain); add_engine(Strategy::Control::FALLBACK, s3_main_strategy_boto2); } @@ -58,11 +58,11 @@ class StrategyRegistry { public: StrategyRegistry(CephContext* const cct, - RGWRados* const store) - : s3_main_strategy(cct, store), - s3_post_strategy(cct, store), - swift_strategy(cct, store), - sts_strategy(cct, store) { + RGWCtl* const ctl) + : s3_main_strategy(cct, ctl), + s3_post_strategy(cct, ctl), + swift_strategy(cct, ctl), + sts_strategy(cct, ctl) { } const s3_main_strategy_t& get_s3_main() const { @@ -83,8 +83,8 @@ public: static std::shared_ptr<StrategyRegistry> create(CephContext* const cct, - RGWRados* const store) { - return std::make_shared<StrategyRegistry>(cct, store); + RGWCtl* const ctl) { + return std::make_shared<StrategyRegistry>(cct, ctl); } }; diff --git a/src/rgw/rgw_auth_s3.h b/src/rgw/rgw_auth_s3.h index 9b9711897ba..31de46fef9a 100644 --- a/src/rgw/rgw_auth_s3.h +++ b/src/rgw/rgw_auth_s3.h @@ -36,7 +36,7 @@ class STSAuthStrategy : public rgw::auth::Strategy, public rgw::auth::LocalApplier::Factory, public rgw::auth::RoleApplier::Factory { typedef rgw::auth::IdentityApplier::aplptr_t aplptr_t; - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; STSEngine sts_engine; @@ -45,8 +45,8 @@ class STSAuthStrategy : public rgw::auth::Strategy, rgw::auth::RemoteApplier::acl_strategy_t&& acl_alg, const rgw::auth::RemoteApplier::AuthInfo &info ) const override { - auto apl = rgw::auth::add_sysreq(cct, user_ctl, s, - rgw::auth::RemoteApplier(cct, user_ctl, std::move(acl_alg), info, + auto apl = rgw::auth::add_sysreq(cct, ctl, s, + rgw::auth::RemoteApplier(cct, ctl, std::move(acl_alg), info, cct->_conf->rgw_keystone_implicit_tenants)); return aplptr_t(new decltype(apl)(std::move(apl))); } @@ -56,7 +56,7 @@ class STSAuthStrategy : public rgw::auth::Strategy, const RGWUserInfo& user_info, const std::string& subuser, const boost::optional<uint32_t>& perm_mask) const override { - auto apl = rgw::auth::add_sysreq(cct, user_ctl, s, + auto apl = rgw::auth::add_sysreq(cct, ctl, s, rgw::auth::LocalApplier(cct, user_info, subuser, perm_mask)); return aplptr_t(new decltype(apl)(std::move(apl))); } @@ -66,17 +66,17 @@ class STSAuthStrategy : public rgw::auth::Strategy, const string& role_name, const rgw_user& user_id, const vector<std::string>& role_policies) const override { - auto apl = rgw::auth::add_sysreq(cct, user_ctl, s, + auto apl = rgw::auth::add_sysreq(cct, ctl, s, rgw::auth::RoleApplier(cct, role_name, user_id, role_policies)); return aplptr_t(new decltype(apl)(std::move(apl))); } public: STSAuthStrategy(CephContext* const cct, - RGWUserCtl* const user_ctl, + RGWCtl* const ctl, AWSEngine::VersionAbstractor* const ver_abstractor) - : user_ctl(user_ctl), - sts_engine(cct, user_ctl, *ver_abstractor, + : ctl(ctl), + sts_engine(cct, ctl, *ver_abstractor, static_cast<rgw::auth::LocalApplier::Factory*>(this), static_cast<rgw::auth::RemoteApplier::Factory*>(this), static_cast<rgw::auth::RoleApplier::Factory*>(this)) { @@ -93,7 +93,7 @@ public: class ExternalAuthStrategy : public rgw::auth::Strategy, public rgw::auth::RemoteApplier::Factory { typedef rgw::auth::IdentityApplier::aplptr_t aplptr_t; - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; using keystone_config_t = rgw::keystone::CephCtxConfig; using keystone_cache_t = rgw::keystone::TokenCache; @@ -108,8 +108,8 @@ class ExternalAuthStrategy : public rgw::auth::Strategy, rgw::auth::RemoteApplier::acl_strategy_t&& acl_alg, const rgw::auth::RemoteApplier::AuthInfo &info ) const override { - auto apl = rgw::auth::add_sysreq(cct, user_ctl, s, - rgw::auth::RemoteApplier(cct, user_ctl, std::move(acl_alg), info, + auto apl = rgw::auth::add_sysreq(cct, ctl, s, + rgw::auth::RemoteApplier(cct, ctl, std::move(acl_alg), info, cct->_conf->rgw_keystone_implicit_tenants)); /* TODO(rzarzynski): replace with static_ptr. */ return aplptr_t(new decltype(apl)(std::move(apl))); @@ -117,10 +117,10 @@ class ExternalAuthStrategy : public rgw::auth::Strategy, public: ExternalAuthStrategy(CephContext* const cct, - RGWUserCtl* const user_ctl, + RGWCtl* const ctl, AWSEngine::VersionAbstractor* const ver_abstractor) - : user_ctl(user_ctl), - ldap_engine(cct, user_ctl, *ver_abstractor, + : ctl(ctl), + ldap_engine(cct, ctl, *ver_abstractor, static_cast<rgw::auth::RemoteApplier::Factory*>(this)) { if (cct->_conf->rgw_s3_auth_use_keystone && @@ -156,7 +156,7 @@ class AWSAuthStrategy : public rgw::auth::Strategy, AbstractorT>::value, "AbstractorT must be a subclass of rgw::auth::s3::VersionAbstractor"); - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; AbstractorT ver_abstractor; S3AnonymousEngine anonymous_engine; @@ -169,7 +169,7 @@ class AWSAuthStrategy : public rgw::auth::Strategy, const RGWUserInfo& user_info, const std::string& subuser, const boost::optional<uint32_t>& perm_mask) const override { - auto apl = rgw::auth::add_sysreq(cct, user_ctl, s, + auto apl = rgw::auth::add_sysreq(cct, ctl, s, rgw::auth::LocalApplier(cct, user_info, subuser, perm_mask)); /* TODO(rzarzynski): replace with static_ptr. */ return aplptr_t(new decltype(apl)(std::move(apl))); @@ -213,14 +213,14 @@ public: } AWSAuthStrategy(CephContext* const cct, - RGWUserCtl* const user_ctl) - : user_ctl(user_ctl), + RGWCtl* const ctl) + : ctl(ctl), ver_abstractor(cct), anonymous_engine(cct, static_cast<rgw::auth::LocalApplier::Factory*>(this)), - external_engines(cct, user_ctl, &ver_abstractor), - sts_engine(cct, user_ctl, &ver_abstractor), - local_engine(cct, user_ctl, ver_abstractor, + external_engines(cct, ctl, &ver_abstractor), + sts_engine(cct, ctl, &ver_abstractor), + local_engine(cct, ctl, ver_abstractor, static_cast<rgw::auth::LocalApplier::Factory*>(this)) { /* The anonymous auth. */ if (AllowAnonAccessT) { diff --git a/src/rgw/rgw_cr_tools.cc b/src/rgw/rgw_cr_tools.cc index f5335d41535..7962f2aaa4a 100644 --- a/src/rgw/rgw_cr_tools.cc +++ b/src/rgw/rgw_cr_tools.cc @@ -89,7 +89,7 @@ int RGWUserCreateCR::Request::_send_request() template<> int RGWGetUserInfoCR::Request::_send_request() { - return store->ctl.ser->get_info_by_uid(params.user, result); + return store->ctl.user->get_info_by_uid(params.user, result); } template<> diff --git a/src/rgw/rgw_op.h b/src/rgw/rgw_op.h index 6ef572eb11e..38e961b67ee 100644 --- a/src/rgw/rgw_op.h +++ b/src/rgw/rgw_op.h @@ -72,27 +72,24 @@ class StrategyRegistry; } int rgw_op_get_bucket_policy_from_attr(CephContext *cct, - RGWRados *store, + RGWUserCtl *user_ctl, RGWBucketInfo& bucket_info, map<string, bufferlist>& bucket_attrs, RGWAccessControlPolicy *policy); class RGWHandler { protected: - RGWRados* store; - struct req_state* s; + RGWRados *store{nullptr}; + struct req_state *s{nullptr}; int do_init_permissions(); int do_read_permissions(RGWOp* op, bool only_bucket); public: - RGWHandler() - : store(nullptr), - s(nullptr) { - } + RGWHandler() {} virtual ~RGWHandler(); - virtual int init(RGWRados* store, + virtual int init(RGWRados *store, struct req_state* _s, rgw::io::BasicClient* cio); diff --git a/src/rgw/rgw_rados.h b/src/rgw/rgw_rados.h index be3a8d7ee9c..558736af0ee 100644 --- a/src/rgw/rgw_rados.h +++ b/src/rgw/rgw_rados.h @@ -488,6 +488,7 @@ public: pools_initialized(false), quota_handler(NULL), cr_registry(NULL), + pctl(&ctl), data_log(NULL), reshard(NULL) {} RGWRados& set_use_cache(bool status) { @@ -538,6 +539,8 @@ public: RGWServices svc; RGWCtl ctl; + RGWCtl *pctl{nullptr}; + /** * AmazonS3 errors contain a HostId string, but is an opaque base64 blob; we * try to be more transparent. This has a wrapper so we can update it when zonegroup/zone are changed. diff --git a/src/rgw/rgw_rest.cc b/src/rgw/rgw_rest.cc index b893e82c2c9..54914deca7c 100644 --- a/src/rgw/rgw_rest.cc +++ b/src/rgw/rgw_rest.cc @@ -1838,7 +1838,7 @@ int RGWHandler_REST::init_permissions(RGWOp* op) if (! s->user->user_id.empty() && s->auth.identity->get_identity_type() != TYPE_ROLE) { try { map<string, bufferlist> uattrs; - if (auto ret = rgw_get_user_attrs_by_uid(store, s->user->user_id, uattrs); ! ret) { + if (auto ret = rgw_get_user_attrs_by_uid(store->ctl.user, s->user->user_id, uattrs); ! ret) { if (s->iam_user_policies.empty()) { s->iam_user_policies = get_iam_user_policy_from_attr(s->cct, store, uattrs, s->user->user_id.tenant); } else { diff --git a/src/rgw/rgw_rest_s3.cc b/src/rgw/rgw_rest_s3.cc index 1b0c2ddf283..ca5b044461b 100644 --- a/src/rgw/rgw_rest_s3.cc +++ b/src/rgw/rgw_rest_s3.cc @@ -1490,7 +1490,7 @@ static int create_s3_policy(struct req_state *s, RGWRados *store, if (!s->canned_acl.empty()) return -ERR_INVALID_REQUEST; - return s3policy.create_from_headers(store, s->info.env, owner); + return s3policy.create_from_headers(store->ctl.user, s->info.env, owner); } return s3policy.create_canned(owner, s->bucket_owner, s->canned_acl); @@ -4935,7 +4935,7 @@ rgw::auth::s3::LocalEngine::authenticate( RGWUserInfo user_info; /* TODO(rzarzynski): we need to have string-view taking variant. */ const std::string access_key_id = _access_key_id.to_string(); - if (rgw_get_user_info_by_access_key(store, access_key_id, user_info) < 0) { + if (rgw_get_user_info_by_access_key(ctl->user, access_key_id, user_info) < 0) { ldpp_dout(dpp, 5) << "error reading user info, uid=" << access_key_id << " can't authenticate" << dendl; return result_t::deny(-ERR_INVALID_ACCESS_KEY); @@ -5100,7 +5100,7 @@ rgw::auth::s3::STSEngine::authenticate( vector<string> role_policies; string role_name; if (! token.roleId.empty()) { - RGWRole role(s->cct, store, token.roleId); + RGWRole role(s->cct, ctl, token.roleId); if (role.get_by_id() < 0) { return result_t::deny(-EPERM); } @@ -5121,7 +5121,7 @@ rgw::auth::s3::STSEngine::authenticate( if (! token.user.empty() && token.acct_type != TYPE_ROLE) { // get user info - int ret = rgw_get_user_info_by_uid(store, token.user, user_info, NULL); + int ret = rgw_get_user_info_by_uid(ctl->user, token.user, user_info, NULL); if (ret < 0) { ldpp_dout(dpp, 5) << "ERROR: failed reading user info: uid=" << token.user << dendl; return result_t::reject(-EPERM); diff --git a/src/rgw/rgw_rest_s3.h b/src/rgw/rgw_rest_s3.h index 003c570a9c7..ab289079dc6 100644 --- a/src/rgw/rgw_rest_s3.h +++ b/src/rgw/rgw_rest_s3.h @@ -922,7 +922,7 @@ class LDAPEngine : public AWSEngine { using result_t = rgw::auth::Engine::result_t; protected: - RGWRados* const store; + RGWCtl* const ctl; const rgw::auth::RemoteApplier::Factory* const apl_factory; acl_strategy_t get_acl_strategy() const; @@ -938,11 +938,11 @@ protected: const req_state* s) const override; public: LDAPEngine(CephContext* const cct, - RGWRados* const store, + RGWCtl* const ctl, const VersionAbstractor& ver_abstractor, const rgw::auth::RemoteApplier::Factory* const apl_factory) : AWSEngine(cct, ver_abstractor), - store(store), + ctl(ctl), apl_factory(apl_factory) { init(cct); } @@ -958,7 +958,7 @@ public: }; class LocalEngine : public AWSEngine { - RGWRados* const store; + RGWCtl* const ctl; const rgw::auth::LocalApplier::Factory* const apl_factory; result_t authenticate(const DoutPrefixProvider* dpp, @@ -971,11 +971,11 @@ class LocalEngine : public AWSEngine { const req_state* s) const override; public: LocalEngine(CephContext* const cct, - RGWRados* const store, + RGWCtl* const ctl, const VersionAbstractor& ver_abstractor, const rgw::auth::LocalApplier::Factory* const apl_factory) : AWSEngine(cct, ver_abstractor), - store(store), + ctl(ctl), apl_factory(apl_factory) { } @@ -987,7 +987,7 @@ public: }; class STSEngine : public AWSEngine { - RGWRados* const store; + RGWCtl* const ctl; const rgw::auth::LocalApplier::Factory* const local_apl_factory; const rgw::auth::RemoteApplier::Factory* const remote_apl_factory; const rgw::auth::RoleApplier::Factory* const role_apl_factory; @@ -1011,13 +1011,13 @@ class STSEngine : public AWSEngine { const req_state* s) const override; public: STSEngine(CephContext* const cct, - RGWRados* const store, + RGWCtl* const ctl, const VersionAbstractor& ver_abstractor, const rgw::auth::LocalApplier::Factory* const local_apl_factory, const rgw::auth::RemoteApplier::Factory* const remote_apl_factory, const rgw::auth::RoleApplier::Factory* const role_apl_factory) : AWSEngine(cct, ver_abstractor), - store(store), + ctl(ctl), local_apl_factory(local_apl_factory), remote_apl_factory(remote_apl_factory), role_apl_factory(role_apl_factory) { @@ -1046,11 +1046,11 @@ public: class S3AuthFactory : public rgw::auth::RemoteApplier::Factory, public rgw::auth::LocalApplier::Factory { typedef rgw::auth::IdentityApplier::aplptr_t aplptr_t; - RGWRados* const store; + RGWCtl* const ctl; public: - explicit S3AuthFactory(RGWRados* const store) - : store(store) { + explicit S3AuthFactory(RGWCtl* const ctl) + : ctl(ctl) { } aplptr_t create_apl_remote(CephContext* const cct, @@ -1059,7 +1059,7 @@ public: const rgw::auth::RemoteApplier::AuthInfo &info ) const override { return aplptr_t( - new rgw::auth::RemoteApplier(cct, store->ctl.user, std::move(acl_alg), info, + new rgw::auth::RemoteApplier(cct, ctl, std::move(acl_alg), info, cct->_conf->rgw_keystone_implicit_tenants)); } diff --git a/src/rgw/rgw_rest_sts.h b/src/rgw/rgw_rest_sts.h index d9baa2c3cac..3fed1e55d0a 100644 --- a/src/rgw/rgw_rest_sts.h +++ b/src/rgw/rgw_rest_sts.h @@ -52,7 +52,7 @@ public: class DefaultStrategy : public rgw::auth::Strategy, public rgw::auth::TokenExtractor, public rgw::auth::WebIdentityApplier::Factory { - RGWRados* const store; + RGWCtl* const ctl; /* The engine. */ const WebTokenEngine web_token_engine; @@ -67,15 +67,15 @@ class DefaultStrategy : public rgw::auth::Strategy, aplptr_t create_apl_web_identity( CephContext* cct, const req_state* s, const rgw::web_idp::WebTokenClaims& token) const override { - auto apl = rgw::auth::add_sysreq(cct, store, s, - rgw::auth::WebIdentityApplier(cct, store, token)); + auto apl = rgw::auth::add_sysreq(cct, ctl, s, + rgw::auth::WebIdentityApplier(cct, ctl, token)); return aplptr_t(new decltype(apl)(std::move(apl))); } public: DefaultStrategy(CephContext* const cct, - RGWRados* const store) - : store(store), + RGWCtl* const ctl) + : ctl(ctl), web_token_engine(cct, static_cast<rgw::auth::TokenExtractor*>(this), static_cast<rgw::auth::WebIdentityApplier::Factory*>(this)) { diff --git a/src/rgw/rgw_role.cc b/src/rgw/rgw_role.cc index 05e0e53d0ac..e4facacbf66 100644 --- a/src/rgw/rgw_role.cc +++ b/src/rgw/rgw_role.cc @@ -38,8 +38,10 @@ int RGWRole::store_info(bool exclusive) bufferlist bl; encode(*this, bl); - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); - return rgw_put_system_obj(obj_ctx, store->svc.zone->get_zone_params().roles_pool, oid, + auto svc = ctl->svc; + + auto obj_ctx = ctl->svc->sysobj->init_obj_ctx(); + return rgw_put_system_obj(obj_ctx, svc->zone->get_zone_params().roles_pool, oid, bl, exclusive, NULL, real_time(), NULL); } @@ -54,8 +56,10 @@ int RGWRole::store_name(bool exclusive) using ceph::encode; encode(nameToId, bl); - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); - return rgw_put_system_obj(obj_ctx, store->svc.zone->get_zone_params().roles_pool, oid, + auto svc = ctl->svc; + + auto obj_ctx = svc->sysobj->init_obj_ctx(); + return rgw_put_system_obj(obj_ctx, svc->zone->get_zone_params().roles_pool, oid, bl, exclusive, NULL, real_time(), NULL); } @@ -63,9 +67,11 @@ int RGWRole::store_path(bool exclusive) { string oid = tenant + get_path_oid_prefix() + path + get_info_oid_prefix() + id; + auto svc = ctl->svc; + bufferlist bl; - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); - return rgw_put_system_obj(obj_ctx, store->svc.zone->get_zone_params().roles_pool, oid, + auto obj_ctx = svc->sysobj->init_obj_ctx(); + return rgw_put_system_obj(obj_ctx, svc->zone->get_zone_params().roles_pool, oid, bl, exclusive, NULL, real_time(), NULL); } @@ -112,7 +118,9 @@ int RGWRole::create(bool exclusive) sprintf(buf + strlen(buf),".%dZ",(int)tv.tv_usec/1000); creation_date.assign(buf, strlen(buf)); - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto svc = ctl->svc; + + auto& pool = svc->zone->get_zone_params().roles_pool; ret = store_info(exclusive); if (ret < 0) { ldout(cct, 0) << "ERROR: storing role info in pool: " << pool.name << ": " @@ -127,7 +135,7 @@ int RGWRole::create(bool exclusive) //Delete the role info that was stored in the previous call string oid = get_info_oid_prefix() + id; - int info_ret = rgw_delete_system_obj(store, pool, oid, NULL); + int info_ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (info_ret < 0) { ldout(cct, 0) << "ERROR: cleanup of role id from pool: " << pool.name << ": " << id << ": " << cpp_strerror(-info_ret) << dendl; @@ -141,14 +149,14 @@ int RGWRole::create(bool exclusive) << path << ": " << cpp_strerror(-ret) << dendl; //Delete the role info that was stored in the previous call string oid = get_info_oid_prefix() + id; - int info_ret = rgw_delete_system_obj(store, pool, oid, NULL); + int info_ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (info_ret < 0) { ldout(cct, 0) << "ERROR: cleanup of role id from pool: " << pool.name << ": " << id << ": " << cpp_strerror(-info_ret) << dendl; } //Delete role name that was stored in previous call oid = tenant + get_names_oid_prefix() + name; - int name_ret = rgw_delete_system_obj(store, pool, oid, NULL); + int name_ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (name_ret < 0) { ldout(cct, 0) << "ERROR: cleanup of role name from pool: " << pool.name << ": " << name << ": " << cpp_strerror(-name_ret) << dendl; @@ -160,7 +168,8 @@ int RGWRole::create(bool exclusive) int RGWRole::delete_obj() { - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto svc = ctl->svc; + auto& pool = svc->zone->get_zone_params().roles_pool; int ret = read_name(); if (ret < 0) { @@ -178,7 +187,7 @@ int RGWRole::delete_obj() // Delete id string oid = get_info_oid_prefix() + id; - ret = rgw_delete_system_obj(store, pool, oid, NULL); + ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (ret < 0) { ldout(cct, 0) << "ERROR: deleting role id from pool: " << pool.name << ": " << id << ": " << cpp_strerror(-ret) << dendl; @@ -186,7 +195,7 @@ int RGWRole::delete_obj() // Delete name oid = tenant + get_names_oid_prefix() + name; - ret = rgw_delete_system_obj(store, pool, oid, NULL); + ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (ret < 0) { ldout(cct, 0) << "ERROR: deleting role name from pool: " << pool.name << ": " << name << ": " << cpp_strerror(-ret) << dendl; @@ -194,7 +203,7 @@ int RGWRole::delete_obj() // Delete path oid = tenant + get_path_oid_prefix() + path + get_info_oid_prefix() + id; - ret = rgw_delete_system_obj(store, pool, oid, NULL); + ret = rgw_delete_system_obj(svc->sysobj, pool, oid, NULL); if (ret < 0) { ldout(cct, 0) << "ERROR: deleting role path from pool: " << pool.name << ": " << path << ": " << cpp_strerror(-ret) << dendl; @@ -229,7 +238,7 @@ int RGWRole::get_by_id() int RGWRole::update() { - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto& pool = ctl->svc->zone->get_zone_params().roles_pool; int ret = store_info(false); if (ret < 0) { @@ -305,10 +314,11 @@ void RGWRole::decode_json(JSONObj *obj) int RGWRole::read_id(const string& role_name, const string& tenant, string& role_id) { - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto svc = ctl->svc; + auto& pool = svc->zone->get_zone_params().roles_pool; string oid = tenant + get_names_oid_prefix() + role_name; bufferlist bl; - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); + auto obj_ctx = svc->sysobj->init_obj_ctx(); int ret = rgw_get_system_obj(obj_ctx, pool, oid, bl, NULL, NULL, null_yield); if (ret < 0) { @@ -331,10 +341,11 @@ int RGWRole::read_id(const string& role_name, const string& tenant, string& role int RGWRole::read_info() { - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto svc = ctl->svc; + auto& pool = svc->zone->get_zone_params().roles_pool; string oid = get_info_oid_prefix() + id; bufferlist bl; - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); + auto obj_ctx = svc->sysobj->init_obj_ctx(); int ret = rgw_get_system_obj(obj_ctx, pool, oid, bl, NULL, NULL, null_yield); if (ret < 0) { @@ -358,10 +369,11 @@ int RGWRole::read_info() int RGWRole::read_name() { - auto& pool = store->svc.zone->get_zone_params().roles_pool; + auto svc = ctl->svc; + auto& pool = svc->zone->get_zone_params().roles_pool; string oid = tenant + get_names_oid_prefix() + name; bufferlist bl; - auto obj_ctx = store->svc.sysobj->init_obj_ctx(); + auto obj_ctx = svc->sysobj->init_obj_ctx(); int ret = rgw_get_system_obj(obj_ctx, pool, oid, bl, NULL, NULL, null_yield); if (ret < 0) { @@ -478,7 +490,7 @@ int RGWRole::get_roles_by_path_prefix(RGWRados *store, //Get id from info oid prefix + id string id = it.substr(pos + role_oid_prefix.length()); - RGWRole role(cct, store); + RGWRole role(cct, store->pctl); role.set_id(id); int ret = role.read_info(); if (ret < 0) { diff --git a/src/rgw/rgw_role.h b/src/rgw/rgw_role.h index 90976099acb..09a69d000ff 100644 --- a/src/rgw/rgw_role.h +++ b/src/rgw/rgw_role.h @@ -8,7 +8,7 @@ #include "common/ceph_context.h" -#include "rgw/rgw_rados.h" +class RGWCtl; class RGWRole { @@ -23,7 +23,7 @@ class RGWRole static constexpr uint64_t SESSION_DURATION_MAX = 43200; // in seconds CephContext *cct; - RGWRados *store; + RGWCtl *ctl; string id; string name; string path; @@ -46,14 +46,14 @@ class RGWRole public: RGWRole(CephContext *cct, - RGWRados *store, + RGWCtl *ctl, string name, string path, string trust_policy, string tenant, string max_session_duration_str="") : cct(cct), - store(store), + ctl(ctl), name(std::move(name)), path(std::move(path)), trust_policy(std::move(trust_policy)), @@ -69,27 +69,27 @@ public: } RGWRole(CephContext *cct, - RGWRados *store, + RGWCtl *ctl, string name, string tenant) : cct(cct), - store(store), + ctl(ctl), name(std::move(name)), tenant(std::move(tenant)) { extract_name_tenant(this->name); } RGWRole(CephContext *cct, - RGWRados *store, + RGWCtl *ctl, string id) : cct(cct), - store(store), + ctl(ctl), id(std::move(id)) {} RGWRole(CephContext *cct, - RGWRados *store) + RGWCtl *ctl) : cct(cct), - store(store) {} + ctl(ctl) {} RGWRole() {} diff --git a/src/rgw/rgw_service.cc b/src/rgw/rgw_service.cc index 899a6c01243..97fe0c632b7 100644 --- a/src/rgw/rgw_service.cc +++ b/src/rgw/rgw_service.cc @@ -5,6 +5,7 @@ #include "services/svc_finisher.h" #include "services/svc_bi_rados.h" +#include "services/svc_bilog_rados.h" #include "services/svc_bucket_sobj.h" #include "services/svc_cls.h" #include "services/svc_mdlog.h" @@ -73,9 +74,9 @@ int RGWServices_Def::init(CephContext *cct, finisher->init(); bi_rados->init(zone.get(), rados.get(), bilog_rados.get()); bilog_rados->init(bi_rados.get()); - bucket->init(zone.get(), sysobj.get(), sysobj_cache.get(), - bi_rados.get(), meta.get(), meta_be_sobj.get(), - sync_modules.get()); + bucket_sobj->init(zone.get(), sysobj.get(), sysobj_cache.get(), + bi_rados.get(), meta.get(), meta_be_sobj.get(), + sync_modules.get()); cls->init(zone.get(), rados.get()); mdlog->init(rados.get(), zone.get(), sysobj.get(), cls.get()); meta->init(sysobj.get(), mdlog.get(), meta_bes); @@ -190,7 +191,7 @@ int RGWServices_Def::init(CephContext *cct, return r; } - r = bucket->start(); + r = bucket_sobj->start(); if (r < 0) { ldout(cct, 0) << "ERROR: failed to start bucket service (" << cpp_strerror(-r) << dendl; return r; @@ -253,7 +254,7 @@ int RGWServices::do_init(CephContext *_cct, bool have_cache, bool raw) bi = bi_rados; bilog_rados = _svc.bilog_rados.get(); bucket_sobj = _svc.bucket_sobj.get(); - bucket = _svc.bucket.get(); + bucket = bucket_sobj; cls = _svc.cls.get(); mdlog = _svc.mdlog.get(); meta = _svc.meta.get(); @@ -336,11 +337,14 @@ int RGWCtlDef::init(RGWServices& svc) return 0; } -int RGWCtl::init(RGWServices& svc) +int RGWCtl::init(RGWServices *_svc) { - int r = _ctl.init(svc); + svc = _svc; + cct = svc->cct; + + int r = _ctl.init(*svc); if (r < 0) { - ldout(svc.cct, 0) << "ERROR: failed to start init ctls (" << cpp_strerror(-r) << dendl; + ldout(cct, 0) << "ERROR: failed to start init ctls (" << cpp_strerror(-r) << dendl; return r; } @@ -356,25 +360,25 @@ int RGWCtl::init(RGWServices& svc) r = meta.user->attach(meta.mgr); if (r < 0) { - ldout(svc.cct, 0) << "ERROR: failed to start init meta.user ctl (" << cpp_strerror(-r) << dendl; + ldout(cct, 0) << "ERROR: failed to start init meta.user ctl (" << cpp_strerror(-r) << dendl; return r; } r = meta.bucket->attach(meta.mgr); if (r < 0) { - ldout(svc.cct, 0) << "ERROR: failed to start init meta.bucket ctl (" << cpp_strerror(-r) << dendl; + ldout(cct, 0) << "ERROR: failed to start init meta.bucket ctl (" << cpp_strerror(-r) << dendl; return r; } r = meta.bucket_instance->attach(meta.mgr); if (r < 0) { - ldout(svc.cct, 0) << "ERROR: failed to start init meta.bucket_instance ctl (" << cpp_strerror(-r) << dendl; + ldout(cct, 0) << "ERROR: failed to start init meta.bucket_instance ctl (" << cpp_strerror(-r) << dendl; return r; } r = meta.otp->attach(meta.mgr); if (r < 0) { - ldout(svc.cct, 0) << "ERROR: failed to start init otp ctl (" << cpp_strerror(-r) << dendl; + ldout(cct, 0) << "ERROR: failed to start init otp ctl (" << cpp_strerror(-r) << dendl; return r; } diff --git a/src/rgw/rgw_service.h b/src/rgw/rgw_service.h index 979385894c1..20616dbb3e4 100644 --- a/src/rgw/rgw_service.h +++ b/src/rgw/rgw_service.h @@ -175,6 +175,9 @@ struct RGWCtlDef { }; struct RGWCtl { + CephContext *cct{nullptr}; + RGWServices *svc{nullptr}; + RGWCtlDef _ctl; struct _meta { @@ -190,7 +193,7 @@ struct RGWCtl { RGWBucketCtl *bucket{nullptr}; RGWOTPCtl *otp{nullptr}; - int init(RGWServices& svc); + int init(RGWServices *_svc); }; #endif diff --git a/src/rgw/rgw_swift_auth.h b/src/rgw/rgw_swift_auth.h index f437e0e5785..f6ddc39c5d7 100644 --- a/src/rgw/rgw_swift_auth.h +++ b/src/rgw/rgw_swift_auth.h @@ -39,7 +39,7 @@ class TempURLEngine : public rgw::auth::Engine { using result_t = rgw::auth::Engine::result_t; CephContext* const cct; - /* const */ RGWUserCtl* const user_ctl; + /* const */ RGWCtl* const ctl; const TempURLApplier::Factory* const apl_factory; /* Helper methods. */ @@ -56,10 +56,10 @@ class TempURLEngine : public rgw::auth::Engine { public: TempURLEngine(CephContext* const cct, - /*const*/ RGWUserCtl* const user_ctl, + /*const*/ RGWCtl* const ctl, const TempURLApplier::Factory* const apl_factory) : cct(cct), - user_ctl(user_ctl), + ctl(ctl), apl_factory(apl_factory) { } @@ -77,7 +77,7 @@ class SignedTokenEngine : public rgw::auth::Engine { using result_t = rgw::auth::Engine::result_t; CephContext* const cct; - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; const rgw::auth::TokenExtractor* const extractor; const rgw::auth::LocalApplier::Factory* const apl_factory; @@ -88,11 +88,11 @@ class SignedTokenEngine : public rgw::auth::Engine { public: SignedTokenEngine(CephContext* const cct, - /* const */RGWUserCtl* const user_ctl, + /* const */RGWCtl* const ctl, const rgw::auth::TokenExtractor* const extractor, const rgw::auth::LocalApplier::Factory* const apl_factory) : cct(cct), - user_ctl(user_ctl), + ctl(ctl), extractor(extractor), apl_factory(apl_factory) { } @@ -112,7 +112,7 @@ class ExternalTokenEngine : public rgw::auth::Engine { using result_t = rgw::auth::Engine::result_t; CephContext* const cct; - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; const rgw::auth::TokenExtractor* const extractor; const rgw::auth::LocalApplier::Factory* const apl_factory; @@ -123,11 +123,11 @@ class ExternalTokenEngine : public rgw::auth::Engine { public: ExternalTokenEngine(CephContext* const cct, - /* const */RGWUserCtl* const user_ctl, + /* const */RGWCtl* const ctl, const rgw::auth::TokenExtractor* const extractor, const rgw::auth::LocalApplier::Factory* const apl_factory) : cct(cct), - user_ctl(user_ctl), + ctl(ctl), extractor(extractor), apl_factory(apl_factory) { } @@ -168,7 +168,7 @@ class DefaultStrategy : public rgw::auth::Strategy, public rgw::auth::RemoteApplier::Factory, public rgw::auth::LocalApplier::Factory, public rgw::auth::swift::TempURLApplier::Factory { - RGWUserCtl* const user_ctl; + RGWCtl* const ctl; /* The engines. */ const rgw::auth::swift::TempURLEngine tempurl_engine; @@ -194,9 +194,9 @@ class DefaultStrategy : public rgw::auth::Strategy, acl_strategy_t&& extra_acl_strategy, const rgw::auth::RemoteApplier::AuthInfo &info) const override { auto apl = \ - rgw::auth::add_3rdparty(user_ctl, s->account_name, - rgw::auth::add_sysreq(cct, user_ctl, s, - rgw::auth::RemoteApplier(cct, user_ctl, std::move(extra_acl_strategy), info, + rgw::auth::add_3rdparty(ctl, s->account_name, + rgw::auth::add_sysreq(cct, ctl, s, + rgw::auth::RemoteApplier(cct, ctl, std::move(extra_acl_strategy), info, cct->_conf->rgw_keystone_implicit_tenants))); /* TODO(rzarzynski): replace with static_ptr. */ return aplptr_t(new decltype(apl)(std::move(apl))); @@ -208,8 +208,8 @@ class DefaultStrategy : public rgw::auth::Strategy, const std::string& subuser, const boost::optional<uint32_t>& perm_mask) const override { auto apl = \ - rgw::auth::add_3rdparty(user_ctl, s->account_name, - rgw::auth::add_sysreq(cct, user_ctl, s, + rgw::auth::add_3rdparty(ctl, s->account_name, + rgw::auth::add_sysreq(cct, ctl, s, rgw::auth::LocalApplier(cct, user_info, subuser, perm_mask))); /* TODO(rzarzynski): replace with static_ptr. */ return aplptr_t(new decltype(apl)(std::move(apl))); @@ -226,17 +226,17 @@ class DefaultStrategy : public rgw::auth::Strategy, public: DefaultStrategy(CephContext* const cct, - RGWUserCtl* const user_ctl) - : user_ctl(user_ctl), + RGWCtl* const ctl) + : ctl(ctl), tempurl_engine(cct, - user_ctl, + ctl, static_cast<rgw::auth::swift::TempURLApplier::Factory*>(this)), signed_engine(cct, - user_ctl, + ctl, static_cast<rgw::auth::TokenExtractor*>(this), static_cast<rgw::auth::LocalApplier::Factory*>(this)), external_engine(cct, - user_ctl, + ctl, static_cast<rgw::auth::TokenExtractor*>(this), static_cast<rgw::auth::LocalApplier::Factory*>(this)), anon_engine(cct, @@ -294,7 +294,7 @@ public: ~RGWHandler_SWIFT_Auth() override {} RGWOp *op_get() override; - int init(RGWUserCtl *user_ctl, struct req_state *state, rgw::io::BasicClient *cio) override; + int init(RGWRados *store, struct req_state *state, rgw::io::BasicClient *cio) override; int authorize(const DoutPrefixProvider *dpp) override; int postauth_init() override { return 0; } int read_permissions(RGWOp *op) override { return 0; } diff --git a/src/rgw/rgw_tools.cc b/src/rgw/rgw_tools.cc index a6b8d8a1c35..c5570c3b05a 100644 --- a/src/rgw/rgw_tools.cc +++ b/src/rgw/rgw_tools.cc @@ -194,10 +194,10 @@ int rgw_get_system_obj(RGWSysObjectCtx& obj_ctx, const rgw_pool& pool, const str return 0; } -int rgw_delete_system_obj(RGWRados *rgwstore, const rgw_pool& pool, const string& oid, +int rgw_delete_system_obj(RGWSI_SysObj *sysobj_svc, const rgw_pool& pool, const string& oid, RGWObjVersionTracker *objv_tracker) { - auto obj_ctx = rgwstore->svc.sysobj->init_obj_ctx(); + auto obj_ctx = sysobj_svc->init_obj_ctx(); auto sysobj = obj_ctx.get_obj(rgw_raw_obj{pool, oid}); rgw_raw_obj obj(pool, oid); return sysobj.wop() diff --git a/src/rgw/rgw_tools.h b/src/rgw/rgw_tools.h index 89fa696927b..2653f3b5c74 100644 --- a/src/rgw/rgw_tools.h +++ b/src/rgw/rgw_tools.h @@ -13,6 +13,8 @@ #include "rgw_common.h" +class RGWSI_SysObj; + class RGWRados; class RGWSysObjectCtx; struct RGWObjVersionTracker; @@ -64,7 +66,7 @@ int rgw_get_system_obj(RGWSysObjectCtx& obj_ctx, const rgw_pool& pool, const str RGWObjVersionTracker *objv_tracker, real_time *pmtime, optional_yield y, map<string, bufferlist> *pattrs = NULL, rgw_cache_entry_info *cache_info = NULL, boost::optional<obj_version> refresh_version = boost::none); -int rgw_delete_system_obj(RGWRados *rgwstore, const rgw_pool& pool, const string& oid, +int rgw_delete_system_obj(RGWSI_SysObj *sysobj_svc, const rgw_pool& pool, const string& oid, RGWObjVersionTracker *objv_tracker); const char *rgw_find_mime_by_ext(string& ext); diff --git a/src/rgw/rgw_trim_mdlog.cc b/src/rgw/rgw_trim_mdlog.cc index 1f951435245..737d79c6455 100644 --- a/src/rgw/rgw_trim_mdlog.cc +++ b/src/rgw/rgw_trim_mdlog.cc @@ -68,7 +68,7 @@ class PurgePeriodLogsCR : public RGWCoroutine { : RGWCoroutine(store->ctx()), store(store), metadata(store->ctl.meta.mgr), realm_epoch(realm_epoch), last_trim_epoch(last_trim) { svc.zone = store->svc.zone; - svc.mdlog = store->svc.mdlog + svc.mdlog = store->svc.mdlog; } int operate() override; diff --git a/src/rgw/services/svc_bi.h b/src/rgw/services/svc_bi.h index e288ad957c2..2ac2d730fa9 100644 --- a/src/rgw/services/svc_bi.h +++ b/src/rgw/services/svc_bi.h @@ -34,5 +34,8 @@ public: virtual int read_stats(const RGWBucketInfo& bucket_info, RGWBucketEnt *stats) = 0; + + virtual int handle_overwrite(const RGWBucketInfo& info, + const RGWBucketInfo& orig_info) = 0; }; diff --git a/src/rgw/services/svc_bi_rados.h b/src/rgw/services/svc_bi_rados.h index 6f66c3b5a66..9e16437fac1 100644 --- a/src/rgw/services/svc_bi_rados.h +++ b/src/rgw/services/svc_bi_rados.h @@ -116,7 +116,7 @@ public: std::list<cls_rgw_bucket_instance_entry> *status); int handle_overwrite(const RGWBucketInfo& info, - const RGWBucketInfo& orig_info); + const RGWBucketInfo& orig_info) override; }; |