]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw/sal: remove load_bucket() overload with tenant/name
authorCasey Bodley <cbodley@redhat.com>
Tue, 3 Oct 2023 19:23:49 +0000 (15:23 -0400)
committerCasey Bodley <cbodley@redhat.com>
Mon, 6 Nov 2023 16:09:04 +0000 (11:09 -0500)
Signed-off-by: Casey Bodley <cbodley@redhat.com>
13 files changed:
src/rgw/driver/daos/rgw_sal_daos.cc
src/rgw/driver/daos/rgw_sal_daos.h
src/rgw/driver/motr/rgw_sal_motr.cc
src/rgw/driver/motr/rgw_sal_motr.h
src/rgw/driver/posix/rgw_sal_posix.cc
src/rgw/driver/posix/rgw_sal_posix.h
src/rgw/driver/rados/rgw_sal_rados.cc
src/rgw/driver/rados/rgw_sal_rados.h
src/rgw/rgw_sal.h
src/rgw/rgw_sal_dbstore.cc
src/rgw/rgw_sal_dbstore.h
src/rgw/rgw_sal_filter.cc
src/rgw/rgw_sal_filter.h

index 167c16d6be97b8501bf060ddfb129d391487e1fa..a6aacf024b3157e8f758346420283d70408a01b4 100644 (file)
@@ -2263,18 +2263,6 @@ int DaosStore::load_bucket(const DoutPrefixProvider* dpp, User* u,
   return (*bucket)->load_bucket(dpp, y);
 }
 
-int DaosStore::load_bucket(const DoutPrefixProvider* dpp, User* u,
-                           const std::string& tenant, const std::string& name,
-                           std::unique_ptr<Bucket>* bucket, optional_yield y) {
-  ldpp_dout(dpp, 20) << "get_bucket" << dendl;
-  rgw_bucket b;
-
-  b.tenant = tenant;
-  b.name = name;
-
-  return load_bucket(dpp, u, b, bucket, y);
-}
-
 bool DaosStore::is_meta_master() { return true; }
 
 int DaosStore::forward_request_to_master(const DoutPrefixProvider* dpp,
index 23f723c0ce7c6fc9399b60b3f60bcc7031d7f0ef..72d3bdb6cfbe1708e4a9ed7bb105a38c096d8240 100644 (file)
@@ -899,10 +899,6 @@ class DaosStore : public StoreDriver {
   int load_bucket(const DoutPrefixProvider* dpp, User* u,
                   const rgw_bucket& b, std::unique_ptr<Bucket>* bucket,
                   optional_yield y) override;
-  int load_bucket(const DoutPrefixProvider* dpp, User* u,
-                  const std::string& tenant, const std::string& name,
-                  std::unique_ptr<Bucket>* bucket,
-                  optional_yield y) override;
   virtual bool is_meta_master() override;
   virtual int forward_request_to_master(const DoutPrefixProvider* dpp,
                                         User* user, obj_version* objv,
index c7e4fc49bd4891294ad7a02c80f88f8fff274123..b53516bb0653cf3218435772ab1ad7c01660e39b 100644 (file)
@@ -3255,16 +3255,6 @@ int MotrStore::load_bucket(const DoutPrefixProvider *dpp, User* u, const rgw_buc
   return (*bucket)->load_bucket(dpp, y);
 }
 
-int MotrStore::load_bucket(const DoutPrefixProvider *dpp, User* u, const std::string& tenant, const std::string& name, std::unique_ptr<Bucket>* bucket, optional_yield y)
-{
-  rgw_bucket b;
-
-  b.tenant = tenant;
-  b.name = name;
-
-  return load_bucket(dpp, u, b, bucket, y);
-}
-
 bool MotrStore::is_meta_master()
 {
   return true;
index ec5eb347cf22733fd73923edd57bf84a2b28b4e7..7935462ac3f0daa9332f91044ae2f3c29f5acb23 100644 (file)
@@ -995,9 +995,6 @@ class MotrStore : public StoreDriver {
     std::unique_ptr<Bucket> get_bucket(User* u, const RGWBucketInfo& i) override;
     int load_bucket(const DoutPrefixProvider *dpp, User* u, const rgw_bucket& b,
                     std::unique_ptr<Bucket>* bucket, optional_yield y) override;
-    int load_bucket(const DoutPrefixProvider *dpp, User* u,
-                    const std::string& tenant, const std::string& name,
-                    std::unique_ptr<Bucket>* bucket, optional_yield y) override;
     virtual bool is_meta_master() override;
     virtual int forward_request_to_master(const DoutPrefixProvider *dpp, User* user, obj_version* objv,
         bufferlist& in_data, JSONParser *jp, req_info& info,
index 40f509b28d74beeb894aca946eb5a1683371e8f1..065d6d2d95dbc914a405d65a0fb88ee2dbc8e671 100644 (file)
@@ -405,16 +405,6 @@ std::unique_ptr<Bucket> POSIXDriver::get_bucket(User* u, const RGWBucketInfo& i)
   return std::make_unique<POSIXBucket>(this, root_fd, i, u);
 }
 
-int POSIXDriver::load_bucket(const DoutPrefixProvider* dpp, User* u, const std::string& tenant, const std::string& name, std::unique_ptr<Bucket>* bucket, optional_yield y)
-{
-  rgw_bucket b;
-
-  b.tenant = tenant;
-  b.name = name;
-
-  return load_bucket(dpp, u, b, bucket, y);
-}
-
 std::string POSIXDriver::zone_unique_trans_id(const uint64_t unique_num)
 {
   char buf[41]; /* 2 + 21 + 1 + 16 (timestamp can consume up to 16) + 1 */
index 53cd05823b6c7c4ad6b5791c0a0f09379f63a0a0..e132f240812bea7160475ea24320e61c63d141d6 100644 (file)
@@ -56,9 +56,6 @@ public:
   virtual int load_bucket(const DoutPrefixProvider* dpp, User* u, const
                          rgw_bucket& b, std::unique_ptr<Bucket>* bucket,
                          optional_yield y) override;
-  virtual int load_bucket(const DoutPrefixProvider* dpp, User* u, const
-                         std::string& tenant, const std::string& name,
-                         std::unique_ptr<Bucket>* bucket, optional_yield y) override;
   virtual std::string zone_unique_trans_id(const uint64_t unique_num) override;
 
   virtual std::unique_ptr<Writer> get_append_writer(const DoutPrefixProvider *dpp,
index 2c526ec940d2877c0f2f33a289a4b1f59c5a7ae4..328b4f82c8f21548b71e0b8380cf007b3f9a314a 100644 (file)
@@ -1068,18 +1068,6 @@ int RadosStore::load_bucket(const DoutPrefixProvider* dpp, User* u, const rgw_bu
   return (*bucket)->load_bucket(dpp, y);
 }
 
-int RadosStore::load_bucket(const DoutPrefixProvider* dpp, User* u,
-                            const std::string& tenant, const std::string& name,
-                            std::unique_ptr<Bucket>* bucket, optional_yield y)
-{
-  rgw_bucket b;
-
-  b.tenant = tenant;
-  b.name = name;
-
-  return load_bucket(dpp, u, b, bucket, y);
-}
-
 bool RadosStore::is_meta_master()
 {
   return svc()->zone->is_meta_master();
index 84a0b6bf95139f999541a088b7cd6a9e40980277..8c1926f3fbef46642366bcc951796fba5cef1739 100644 (file)
@@ -140,9 +140,6 @@ class RadosStore : public StoreDriver {
     std::unique_ptr<Bucket> get_bucket(User* u, const RGWBucketInfo& i) override;
     int load_bucket(const DoutPrefixProvider* dpp, User* u, const rgw_bucket& b,
                     std::unique_ptr<Bucket>* bucket, optional_yield y) override;
-    int load_bucket(const DoutPrefixProvider* dpp, User* u,
-                    const std::string& tenant, const std::string& name,
-                    std::unique_ptr<Bucket>* bucket, optional_yield y) override;
     virtual bool is_meta_master() override;
     virtual int forward_request_to_master(const DoutPrefixProvider *dpp, User* user, obj_version* objv,
                                          bufferlist& in_data, JSONParser* jp, req_info& info,
index de5a2f7dda13ef4d12f918c462f54a7edfe8be65..d69942532881cab817c4038c444070bc5f13a23f 100644 (file)
@@ -295,10 +295,6 @@ class Driver {
      * bucket must still be allocated to support bucket->create(). */
     virtual int load_bucket(const DoutPrefixProvider* dpp, User* u, const rgw_bucket& b,
                             std::unique_ptr<Bucket>* bucket, optional_yield y) = 0;
-    /** Load a Bucket by name.  Queries driver for bucket info. */
-    virtual int load_bucket(const DoutPrefixProvider* dpp, User* u,
-                            const std::string& tenant, const std::string& name,
-                            std::unique_ptr<Bucket>* bucket, optional_yield y) = 0;
     /** For multisite, this driver is the zone's master */
     virtual bool is_meta_master() = 0;
     /** For multisite, forward an OP to the zone's master */
index 7f9ad515ec2159edf2633b82ead29e7b87fc317d..792fa457f895274dbdd891a4b76aefbf71c5c23f 100644 (file)
@@ -1646,18 +1646,6 @@ namespace rgw::sal {
     return (*bucket)->load_bucket(dpp, y);
   }
 
-  int DBStore::load_bucket(const DoutPrefixProvider *dpp, User* u,
-                           const std::string& tenant, const std::string& name,
-                           std::unique_ptr<Bucket>* bucket, optional_yield y)
-  {
-    rgw_bucket b;
-
-    b.tenant = tenant;
-    b.name = name;
-
-    return load_bucket(dpp, u, b, bucket, y);
-  }
-
   bool DBStore::is_meta_master()
   {
     return true;
index e352af98b14348bd3948220a62f63e6dd3193ca9..41a0b89ea50296153abd23c8beec73b6db6c0f50 100644 (file)
@@ -781,9 +781,6 @@ public:
       std::unique_ptr<Bucket> get_bucket(User* u, const RGWBucketInfo& i) override;
       int load_bucket(const DoutPrefixProvider *dpp, User* u, const rgw_bucket& b,
                       std::unique_ptr<Bucket>* bucket, optional_yield y) override;
-      int load_bucket(const DoutPrefixProvider *dpp, User* u,
-                      const std::string& tenant, const std::string&name,
-                      std::unique_ptr<Bucket>* bucket, optional_yield y) override;
       virtual bool is_meta_master() override;
       virtual int forward_request_to_master(const DoutPrefixProvider *dpp, User* user, obj_version* objv,
           bufferlist& in_data, JSONParser *jp, req_info& info,
index fc5eecc008fd26981f163a822cda73f38385705d..c70d9e372dc306e61f7ecc971d3fff0e4cfa778c 100644 (file)
@@ -174,16 +174,6 @@ int FilterDriver::load_bucket(const DoutPrefixProvider* dpp, User* u, const rgw_
   return ret;
 }
 
-int FilterDriver::load_bucket(const DoutPrefixProvider* dpp, User* u,
-                              const std::string& tenant, const std::string& name,
-                              std::unique_ptr<Bucket>* bucket, optional_yield y)
-{
-  std::unique_ptr<Bucket> nb;
-  const int ret = next->load_bucket(dpp, nextUser(u), tenant, name, &nb, y);
-  *bucket = std::make_unique<FilterBucket>(std::move(nb), u);
-  return ret;
-}
-
 bool FilterDriver::is_meta_master()
 {
   return next->is_meta_master();
index e33c84871a7ac4d08844ecd6460c298de2ec2992..b2aa1be399f3f9d98a9f8107d2ac028de1d6e548 100644 (file)
@@ -160,12 +160,9 @@ public:
                                std::unique_ptr<User>* user) override;
   virtual std::unique_ptr<Object> get_object(const rgw_obj_key& k) override;
   std::unique_ptr<Bucket> get_bucket(User* u, const RGWBucketInfo& i) override;
-  int load_bucket(const DoutPrefixProvider* dpp, User* u, const
-                  rgw_bucket& b, std::unique_ptr<Bucket>* bucket,
+  int load_bucket(const DoutPrefixProvider* dpp, User* u,
+                  const rgw_bucket& b, std::unique_ptr<Bucket>* bucket,
                   optional_yield y) override;
-  int load_bucket(const DoutPrefixProvider* dpp, User* u, const
-                  std::string& tenant, const std::string& name,
-                  std::unique_ptr<Bucket>* bucket, optional_yield y) override;
   virtual bool is_meta_master() override;
   virtual int forward_request_to_master(const DoutPrefixProvider *dpp, User* user,
                                        obj_version* objv, bufferlist& in_data,