Since buckets can undergo resharding which changes the bucket id, using the
bucket marker in the shard id can help prevent the need to rewrite the entry as
the buckets get resharded. This also helps detect the exit criteria when the
bucket gets deleted.
Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
(cherry picked from commit
bf64aa843febf2f09aab54f9e0a24aa44f5938ea)
static int guard_lc_modify(RGWRados* store, const rgw_bucket& bucket, const string& cookie, const F& f) {
CephContext *cct = store->ctx();
- string shard_id = bucket.tenant + ':' + bucket.name + ':' + bucket.bucket_id;
+ string shard_id = bucket.tenant + ':' + bucket.name + ':' + bucket.marker;
string oid;
get_lc_oid(cct, shard_id, &oid);