From 59e8ddaa5c0f96728f78ea985673fc0b8499c1a6 Mon Sep 17 00:00:00 2001 From: Jiaying Ren Date: Mon, 19 Jun 2017 23:35:46 +0800 Subject: [PATCH] rgw: miis trivial cleanup + drop outdated & misplaced function description + drop unused func find_placement Signed-off-by: Jiaying Ren --- src/rgw/rgw_rados.cc | 4 ---- src/rgw/rgw_rados.h | 17 ----------------- 2 files changed, 21 deletions(-) diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc index b116eea2b7374..fb25357888f4c 100644 --- a/src/rgw/rgw_rados.cc +++ b/src/rgw/rgw_rados.cc @@ -5743,10 +5743,6 @@ void RGWRados::create_bucket_id(string *bucket_id) *bucket_id = buf; } -/** - * create a bucket with name bucket and the given list of attrs - * returns 0 on success, -ERR# otherwise. - */ int RGWRados::create_bucket(RGWUserInfo& owner, rgw_bucket& bucket, const string& zonegroup_id, const string& placement_rule, diff --git a/src/rgw/rgw_rados.h b/src/rgw/rgw_rados.h index 6b996c960bfbf..76be577d40408 100644 --- a/src/rgw/rgw_rados.h +++ b/src/rgw/rgw_rados.h @@ -1274,19 +1274,6 @@ struct RGWZoneParams : RGWSystemMetaObj { void decode_json(JSONObj *obj); static void generate_test_instances(list& o); - bool find_placement(const rgw_data_placement_target& placement, string *placement_id) { - for (const auto& pp : placement_pools) { - const RGWZonePlacementInfo& info = pp.second; - if (info.index_pool == placement.index_pool.to_str() && - info.data_pool == placement.data_pool.to_str() && - info.data_extra_pool == placement.data_extra_pool.to_str()) { - *placement_id = pp.first; - return true; - } - } - return false; - } - bool get_placement(const string& placement_id, RGWZonePlacementInfo *placement) const { auto iter = placement_pools.find(placement_id); if (iter == placement_pools.end()) { @@ -2595,10 +2582,6 @@ public: int create_pool(const rgw_pool& pool); - /** - * create a bucket with name bucket and the given list of attrs - * returns 0 on success, -ERR# otherwise. - */ int init_bucket_index(RGWBucketInfo& bucket_info, int num_shards); int select_bucket_placement(RGWUserInfo& user_info, const string& zonegroup_id, const string& rule, string *pselected_rule_name, RGWZonePlacementInfo *rule_info); -- 2.39.5