diff options
author | Casey Bodley <cbodley@redhat.com> | 2023-03-18 21:55:58 +0100 |
---|---|---|
committer | Casey Bodley <cbodley@redhat.com> | 2023-11-07 18:18:17 +0100 |
commit | d2dbe7550296da6db885b5344c71f77f9acbfd8f (patch) | |
tree | 6bc259d76864a78042b467ebc4b348438c1601f1 /src/rgw/rgw_rest_user_policy.cc | |
parent | rgw: forward_request takes const req_info (diff) | |
download | ceph-d2dbe7550296da6db885b5344c71f77f9acbfd8f.tar.xz ceph-d2dbe7550296da6db885b5344c71f77f9acbfd8f.zip |
rgw: add free function rgw_forward_request_to_master()
Signed-off-by: Casey Bodley <cbodley@redhat.com>
Diffstat (limited to 'src/rgw/rgw_rest_user_policy.cc')
-rw-r--r-- | src/rgw/rgw_rest_user_policy.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/rgw/rgw_rest_user_policy.cc b/src/rgw/rgw_rest_user_policy.cc index 2e300468b95..ddca86a95d8 100644 --- a/src/rgw/rgw_rest_user_policy.cc +++ b/src/rgw/rgw_rest_user_policy.cc @@ -13,6 +13,7 @@ #include "rgw_common.h" #include "rgw_op.h" +#include "rgw_process_env.h" #include "rgw_rest.h" #include "rgw_rest_user_policy.h" #include "rgw_sal.h" @@ -131,8 +132,8 @@ void RGWPutUserPolicy::execute(optional_yield y) return; } - ceph::bufferlist in_data; - op_ret = driver->forward_request_to_master(this, s->user.get(), nullptr, in_data, nullptr, s->info, y); + op_ret = rgw_forward_request_to_master(this, *s->penv.site, s->user->get_id(), + nullptr, nullptr, s->info, y); if (op_ret < 0) { ldpp_dout(this, 0) << "ERROR: forward_request_to_master returned ret=" << op_ret << dendl; return; @@ -362,8 +363,8 @@ void RGWDeleteUserPolicy::execute(optional_yield y) return; } - ceph::bufferlist in_data; - op_ret = driver->forward_request_to_master(this, s->user.get(), nullptr, in_data, nullptr, s->info, y); + op_ret = rgw_forward_request_to_master(this, *s->penv.site, s->user->get_id(), + nullptr, nullptr, s->info, y); if (op_ret < 0) { // a policy might've been uploaded to this site when there was no sync // req. in earlier releases, proceed deletion |