On Mon, Apr 24, 2023 at 3:36 PM Yixin Jin <yjin77@xxxxxxxx> wrote: > > Hi folks, > > I noticed that rgw data logs are generated with a timestamp (cls_log_entry in cls_log_types.h), which seems to be used to ensure a certain order among all logs from peers in a zonegroup during sync. Since machine clocks are not perfectly in sync and using timestamps from different machines may lead to the different order than what truly has happen, how does ceph/rgw protect itself against this issue? Originally, I thought it gets a monotonic ID from the master zone or using master zone's timestamp. It doesn't seem to be the case or did I read the code wrong? > > Thanks, > Yixin > _______________________________________________ > Dev mailing list -- dev@xxxxxxx > To unsubscribe send an email to dev-leave@xxxxxxx the datalog timestamps are not compared across source zones like this. data sync just processes the stream of datalog events from a given source zone and spawns bucket sync for each one timestamps only come into play when replicating objects. if a local copy of the destination object already exists, the GET request to fetch it will include the local object's mtime in an If-Modified-Since header. the object will be only be transferred if the source zone has a more recent copy you're right that clock skew between zones may not preserve the true order of uploads, but this strategy at least guarantees that all zones will converge on the same object upload with the highest mtime _______________________________________________ Dev mailing list -- dev@xxxxxxx To unsubscribe send an email to dev-leave@xxxxxxx