summaryrefslogtreecommitdiffstats
path: root/src/rgw/rgw_orphan.cc
diff options
context:
space:
mode:
authorroot <root@localhost.localdomain>2021-01-13 08:19:08 +0100
committerroot <root@localhost.localdomain>2021-02-07 16:16:49 +0100
commita53c206f6373cb15bb20844d95747074aa0fc87f (patch)
tree853b99a83a516eaf7b0aab870eaf7fb0463c2f3b /src/rgw/rgw_orphan.cc
parentMerge pull request #39196 from badone/wip-doc-python3-api (diff)
downloadceph-a53c206f6373cb15bb20844d95747074aa0fc87f.tar.xz
ceph-a53c206f6373cb15bb20844d95747074aa0fc87f.zip
rgw: Dpp addition to create bucket log
This commit adds dpp to the create bucket log. Signed-off-by: Kalpesh Pandya <kapandya@redhat.com>
Diffstat (limited to 'src/rgw/rgw_orphan.cc')
-rw-r--r--src/rgw/rgw_orphan.cc48
1 files changed, 24 insertions, 24 deletions
diff --git a/src/rgw/rgw_orphan.cc b/src/rgw/rgw_orphan.cc
index 50574e4ac88..d1b7e260808 100644
--- a/src/rgw/rgw_orphan.cc
+++ b/src/rgw/rgw_orphan.cc
@@ -496,7 +496,7 @@ int RGWOrphanSearch::build_linked_oids_for_bucket(const DoutPrefixProvider *dpp,
int ret = rgw_bucket_parse_bucket_key(store->ctx(), bucket_instance_id,
&orphan_bucket, &shard_id);
if (ret < 0) {
- ldout(store->ctx(),0) << __func__ << " failed to parse bucket instance: "
+ ldpp_dout(dpp, 0) << __func__ << " failed to parse bucket instance: "
<< bucket_instance_id << " skipping" << dendl;
return ret;
}
@@ -509,19 +509,19 @@ int RGWOrphanSearch::build_linked_oids_for_bucket(const DoutPrefixProvider *dpp,
/* probably raced with bucket removal */
return 0;
}
- lderr(store->ctx()) << __func__ << ": ERROR: RGWRados::get_bucket_instance_info() returned ret=" << ret << dendl;
+ ldpp_dout(dpp, -1) << __func__ << ": ERROR: RGWRados::get_bucket_instance_info() returned ret=" << ret << dendl;
return ret;
}
if (cur_bucket_info.bucket.bucket_id != orphan_bucket.bucket_id) {
- ldout(store->ctx(), 0) << __func__ << ": Skipping stale bucket instance: "
+ ldpp_dout(dpp, 0) << __func__ << ": Skipping stale bucket instance: "
<< orphan_bucket.name << ": "
<< orphan_bucket.bucket_id << dendl;
return 0;
}
if (cur_bucket_info.reshard_status == cls_rgw_reshard_status::IN_PROGRESS) {
- ldout(store->ctx(), 0) << __func__ << ": reshard in progress. Skipping "
+ ldpp_dout(dpp, 0) << __func__ << ": reshard in progress. Skipping "
<< orphan_bucket.name << ": "
<< orphan_bucket.bucket_id << dendl;
return 0;
@@ -534,11 +534,11 @@ int RGWOrphanSearch::build_linked_oids_for_bucket(const DoutPrefixProvider *dpp,
/* probably raced with bucket removal */
return 0;
}
- lderr(store->ctx()) << __func__ << ": ERROR: RGWRados::get_bucket_instance_info() returned ret=" << ret << dendl;
+ ldpp_dout(dpp, -1) << __func__ << ": ERROR: RGWRados::get_bucket_instance_info() returned ret=" << ret << dendl;
return ret;
}
- ldout(store->ctx(), 10) << "building linked oids for bucket instance: " << bucket_instance_id << dendl;
+ ldpp_dout(dpp, 10) << "building linked oids for bucket instance: " << bucket_instance_id << dendl;
RGWRados::Bucket target(store->getRados(), bucket_info);
RGWRados::Bucket::List list_op(&target);
@@ -564,16 +564,16 @@ int RGWOrphanSearch::build_linked_oids_for_bucket(const DoutPrefixProvider *dpp,
for (vector<rgw_bucket_dir_entry>::iterator iter = result.begin(); iter != result.end(); ++iter) {
rgw_bucket_dir_entry& entry = *iter;
if (entry.key.instance.empty()) {
- ldout(store->ctx(), 20) << "obj entry: " << entry.key.name << dendl;
+ ldpp_dout(dpp, 20) << "obj entry: " << entry.key.name << dendl;
} else {
- ldout(store->ctx(), 20) << "obj entry: " << entry.key.name << " [" << entry.key.instance << "]" << dendl;
+ ldpp_dout(dpp, 20) << "obj entry: " << entry.key.name << " [" << entry.key.instance << "]" << dendl;
}
- ldout(store->ctx(), 20) << __func__ << ": entry.key.name=" << entry.key.name << " entry.key.instance=" << entry.key.instance << dendl;
+ ldpp_dout(dpp, 20) << __func__ << ": entry.key.name=" << entry.key.name << " entry.key.instance=" << entry.key.instance << dendl;
if (!detailed_mode &&
entry.meta.accounted_size <= (uint64_t)store->ctx()->_conf->rgw_max_chunk_size) {
- ldout(store->ctx(),5) << __func__ << "skipping stat as the object " << entry.key.name
+ ldpp_dout(dpp, 5) << __func__ << "skipping stat as the object " << entry.key.name
<< "fits in a head" << dendl;
continue;
}
@@ -627,7 +627,7 @@ int RGWOrphanSearch::build_linked_oids_index(const DoutPrefixProvider *dpp)
map<int, list<string> > oids;
map<int, string>::iterator iter = buckets_instance_index.find(search_stage.shard);
for (; iter != buckets_instance_index.end(); ++iter) {
- ldout(store->ctx(), 0) << "building linked oids index: " << iter->first << "/" << buckets_instance_index.size() << dendl;
+ ldpp_dout(dpp, 0) << "building linked oids index: " << iter->first << "/" << buckets_instance_index.size() << dendl;
bool truncated;
string oid = iter->second;
@@ -811,7 +811,7 @@ int RGWOrphanSearch::run(const DoutPrefixProvider *dpp)
switch (search_stage.stage) {
case ORPHAN_SEARCH_STAGE_INIT:
- ldout(store->ctx(), 0) << __func__ << "(): initializing state" << dendl;
+ ldpp_dout(dpp, 0) << __func__ << "(): initializing state" << dendl;
search_stage = RGWOrphanSearchStage(ORPHAN_SEARCH_STAGE_LSPOOL);
r = save_state();
if (r < 0) {
@@ -820,7 +820,7 @@ int RGWOrphanSearch::run(const DoutPrefixProvider *dpp)
}
// fall through
case ORPHAN_SEARCH_STAGE_LSPOOL:
- ldout(store->ctx(), 0) << __func__ << "(): building index of all objects in pool" << dendl;
+ ldpp_dout(dpp, 0) << __func__ << "(): building index of all objects in pool" << dendl;
r = build_all_oids_index();
if (r < 0) {
lderr(store->ctx()) << __func__ << ": ERROR: build_all_objs_index returned ret=" << r << dendl;
@@ -836,7 +836,7 @@ int RGWOrphanSearch::run(const DoutPrefixProvider *dpp)
// fall through
case ORPHAN_SEARCH_STAGE_LSBUCKETS:
- ldout(store->ctx(), 0) << __func__ << "(): building index of all bucket indexes" << dendl;
+ ldpp_dout(dpp, 0) << __func__ << "(): building index of all bucket indexes" << dendl;
r = build_buckets_instance_index();
if (r < 0) {
lderr(store->ctx()) << __func__ << ": ERROR: build_all_objs_index returned ret=" << r << dendl;
@@ -1148,7 +1148,7 @@ int RGWRadosList::process_bucket(
const std::string& prefix,
const std::set<rgw_obj_key>& entries_filter)
{
- ldout(store->ctx(), 10) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, 10) << "RGWRadosList::" << __func__ <<
" bucket_instance_id=" << bucket_instance_id <<
", prefix=" << prefix <<
", entries_filter.size=" << entries_filter.size() << dendl;
@@ -1167,7 +1167,7 @@ int RGWRadosList::process_bucket(
// probably raced with bucket removal
return 0;
}
- lderr(store->ctx()) << __func__ <<
+ ldpp_dout(dpp, -1) << __func__ <<
": ERROR: RGWRados::get_bucket_instance_info() returned ret=" <<
ret << dendl;
return ret;
@@ -1212,13 +1212,13 @@ int RGWRadosList::process_bucket(
rgw_bucket_dir_entry& entry = *iter;
if (entry.key.instance.empty()) {
- ldout(store->ctx(), 20) << "obj entry: " << entry.key.name << dendl;
+ ldpp_dout(dpp, 20) << "obj entry: " << entry.key.name << dendl;
} else {
- ldout(store->ctx(), 20) << "obj entry: " << entry.key.name <<
+ ldpp_dout(dpp, 20) << "obj entry: " << entry.key.name <<
" [" << entry.key.instance << "]" << dendl;
}
- ldout(store->ctx(), 20) << __func__ << ": entry.key.name=" <<
+ ldpp_dout(dpp, 20) << __func__ << ": entry.key.name=" <<
entry.key.name << " entry.key.instance=" << entry.key.instance <<
dendl;
@@ -1388,7 +1388,7 @@ int RGWRadosList::run(const DoutPrefixProvider *dpp, const std::string& start_bu
// bucket deletion race?
return 0;
} if (ret < 0) {
- lderr(store->ctx()) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, -1) << "RGWRadosList::" << __func__ <<
": ERROR: process_bucket(); bucket_id=" <<
bucket_id << " returned ret=" << ret << dendl;
}
@@ -1434,7 +1434,7 @@ int RGWRadosList::run(const DoutPrefixProvider *dpp, const std::string& start_bu
// bucket deletion race?
return 0;
} else if (ret < 0) {
- lderr(store->ctx()) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, -1) << "RGWRadosList::" << __func__ <<
": ERROR: get_bucket_info returned ret=" << ret << dendl;
return ret;
}
@@ -1478,12 +1478,12 @@ int RGWRadosList::do_incomplete_multipart(
&is_listing_truncated, null_yield);
if (ret == -ENOENT) {
// could bucket have been removed while this is running?
- ldout(store->ctx(), 20) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, 20) << "RGWRadosList::" << __func__ <<
": WARNING: call to list_objects of multipart namespace got ENOENT; "
"assuming bucket removal race" << dendl;
break;
} else if (ret < 0) {
- lderr(store->ctx()) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, -1) << "RGWRadosList::" << __func__ <<
": ERROR: list_objects op returned ret=" << ret << dendl;
return ret;
}
@@ -1499,7 +1499,7 @@ int RGWRadosList::do_incomplete_multipart(
}
entry.obj = obj;
uploads.push_back(entry);
- ldout(store->ctx(), 20) << "RGWRadosList::" << __func__ <<
+ ldpp_dout(dpp, 20) << "RGWRadosList::" << __func__ <<
" processing incomplete multipart entry " <<
entry << dendl;
}