diff --git a/src/doc/rgw/multisite-reshard.md b/src/doc/rgw/multisite-reshard.md index b2111deb5932f..32715290ebc18 100644 --- a/src/doc/rgw/multisite-reshard.md +++ b/src/doc/rgw/multisite-reshard.md @@ -72,10 +72,19 @@ The distinction between *index layout* and *log layout* is important, because in * Full sync uses a single bucket-wide listing to fetch all objects. - Use a cls_lock to prevent different shards from duplicating this work. * When incremental sync gets to the end of a log shard (i.e. listing the log returns truncated=false): - - If the remote has a newer log generation, flag that shard as 'resharded' in the bucket sync status. - - Once all shards in the current generation reach that 'resharded' state, incremental bucket sync can advance to the next generation. + - If the remote has a newer log generation, flag that shard as 'done' in the bucket sync status. + - Once all shards in the current generation reach that 'done' state, incremental bucket sync can advance to the next generation. - Use cls_version on the bucket sync status object to detect racing writes from other shards. +### Bucket Sync Disable/Enable + +Reframe in terms of log generations, instead of handling SYNCSTOP events with a special Stopped state: + +* radosgw-admin bucket sync enable: create a new log generation in the bucket instance metadata + - detect races with reshard: fail if reshard in progress, and write with cls_version to detect race with start of reshard + - if the current log generation is shared with the bucket index layout (BucketLogType::InIndex), the new log generation will point at the same index layout/generation. so the log generation increments, but the index objects keep the same generation +* SYNCSTOP in incremental sync: flag the shard as 'done' and ignore datalog events on that bucket until we see a new generation + ### Log Trimming * Use generation number from sync status to trim the right logs