Repository navigation
rgw: implements timestamp-based epochs for versioned objects - #62469
Conversation
d7e1c56 to
496405f
Compare
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
cbodley
left a comment
There was a problem hiding this comment.
very nice, thanks for adding the comments!
86d9249 to
e67c6d2
Compare
e93a694 to
0aa3fd8
Compare
cbodley
left a comment
There was a problem hiding this comment.
code changes look good 👍
169dbf9 to
4952ff7
Compare
There was a problem hiding this comment.
so this relies on radosgw-admin bucket list for access to olh epochs, and reproduces internal logic for ordering.. but wouldn't we get the same test coverage by comparing the outputs from s3 ListObjectVersions?
zonegroup_bucket_checkpoint() is already calling check_bucket_eq() to verify that versioned listings look the same on all zones. are you sure we need check_modification_history()?
There was a problem hiding this comment.
I moved away from using s3 ListObjectVersions because I noticed in some more intense tests I did it was truncating the mtime - so my test would start to fail.
zonegroup_bucket_checkpoint() is already calling check_bucket_eq() to verify that versioned listings look the same
Oh - I didn't realize that.. hmm
There was a problem hiding this comment.
One thing that check_modification_history() does (that I don't see in check_bucket_eq()) is checking for out-of-order versions. This was a problem with monotonically increasing epochs but shouldn't be a problem with the timestamp-based epochs. Thus I believe we should keep. Do you agree?
There was a problem hiding this comment.
One thing that
check_modification_history()does (that I don't see incheck_bucket_eq()) is checking for out-of-order versions
my understanding of for k1, k2 in zip_longest(b1_versions, b2_versions) in check_bucket_eq() is that it compares the listings entry-by-entry, so we'd see comparisons fail if ordered differently
There was a problem hiding this comment.
Yes, but versions might be listed in both zones out of order: older first, newer then. With monotonically increasing epochs when an epoch collision would happen it would be resolved view lexicographical comparison - so older version might get ahead of the newer in the OLH history - thus bucket listing would not be in chronological order in both zones. Not so with timestamp-based epochs. Hence the check.
There was a problem hiding this comment.
ok, but src/test/cls_rgw/test_cls_rgw.cc would probably be a better place to set up specific races and verify that listing gives the order we expect. this stuff is best exercised against a single index shard on a single zone
edit to add: the problem with relying on multisite tests for this coverage is that we can't reliably produce these races. if the races are probabilistic, a passing test doesn't prove correctness
There was a problem hiding this comment.
As agreed I will publish a separate PR that will add a new test in test_cls_rgw.cc to reproduce race conditions in a deterministic manner
c448012 to
03fb249
Compare
you wouldn't think these are related, but they're linting our tests: |
b0eed07 to
61174d2
Compare
There was a problem hiding this comment.
nit: i searched the test results for test_timestamp_based_epochs but it doesn't show up. when nose runs this test, it's displayed as:
tasks.rgw_multisite_tests:the test generates objects/instance in both zones: for each of NUM_OBJECTS NUM_VERSIONS are generated; ... ok
There was a problem hiding this comment.
Yeah, I've added the docstring to my test. Should I remove it?
There was a problem hiding this comment.
maybe just put test_timestamp_based_epochs by itself on the first line? up to you
please also squash the commits, and this is ready to merge
There was a problem hiding this comment.
@cbodley Can this merge, or is it waiting for something?
@adamemerson just waiting on above ^
There was a problem hiding this comment.
@cbodley commits squashed, about the test_timestamp_based_epochs() - I'm not sure what you meant...
There was a problem hiding this comment.
@igomon-bloomberg in the nose log output, i'd prefer to see the function name instead of first line of docstring:
tasks.rgw_multisite_tests:the test generates objects/instance in both zones: for each of NUM_OBJECTS NUM_VERSIONS are generated; ... ok
most other test cases don't have a docstring. the ones that do, like test_sync_multiple_buckets_to_single(), repeat the function name as the first line of docstring:
def test_sync_multiple_buckets_to_single():
"""
test_sync_multiple_buckets_to_single:
directional flow
(a) pipe: sync zoneA bucketA,bucketB to zoneB bucketB
(b) configure another policy at bucketA level with pipe configured
to sync from multiple buckets (bucketA & bucketB)
verify zoneA bucketA & bucketB syncs to zoneB BucketB
"""this way we can still grep the log for test function names to verify that they ran/passed
|
results look great! the two-zone multisite job passed
|
|
jenkins test make check arm64 |
|
@cbodley Can this merge, or is it waiting for something? |
61174d2 to
032b22d
Compare
Signed-off-by: Igor Gomon <[email protected]>
032b22d to
4195486
Compare
commented again in https://tracker.ceph.com/issues/70691 |
|
jenkins test make check arm64 |
|
thanks @igomon-bloomberg! |
|
@igomon-bloomberg : We have a tracker that matches a downstream issue we faced, and the fix was to revert the one commit in this PR. The same issue has now been reported upstream here: https://tracker.ceph.com/issues/75777 . So would you prefer to revert this PR or would you like to try to address the tracker (or alternatively show that this PR is not responsible)? Thanks! cc: @cbodley . |
|
thanks @ivancich. the downstream reproducer for https://tracker.ceph.com/issues/75777 was showing a ton of leftover olh/instance entries, which is why listings started to fail with EFBIG i think https://tracker.ceph.com/issues/74428 is the most relevant tracker for this, and @jzhu116-bloomberg is working on this in #67661 for https://tracker.ceph.com/issues/75340 |
|
Yes, @jzhu116-bloomberg is already working on the fix in #67661, I believe. |
…read decreasing_str prints every epoch from 2^32 up as a negative or 21-digit number. decode_list_index_key refuses both, so bucket listings skip those versions, and the negative form sorts in ascending epoch order ahead of the lower bands, so deleting the current version can make an older one than the next-newest current, or remove the key. That holds on Squid and Tentacle; v21.0.0 widens the bands (ceph/ceph#62469). read_olh_log dereferences the first epoch of a pending log before it knows the log holds one, which changes no answer. Co-Authored-By: Claude Opus 5.5 <[email protected]>
rgw: implements timestamp-based epochs for objects in versioned buckets.
Fixes: https://tracker.ceph.com/issues/68466
Signed-off-by: Igor Gomon [email protected]
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an
xbetween the brackets:[x]. Spaces and capitalization matter when checking off items this way.Checklist
Show available Jenkins commands
jenkins test classic perfJenkins Job | Jenkins Job Definitionjenkins test crimson perfJenkins Job | Jenkins Job Definitionjenkins test signedJenkins Job | Jenkins Job Definitionjenkins test make checkJenkins Job | Jenkins Job Definitionjenkins test make check arm64Jenkins Job | Jenkins Job Definitionjenkins test submodulesJenkins Job | Jenkins Job Definitionjenkins test dashboardJenkins Job | Jenkins Job Definitionjenkins test dashboard cephadmJenkins Job | Jenkins Job Definitionjenkins test apiJenkins Job | Jenkins Job Definitionjenkins test docsReadTheDocs | Github Workflow Definitionjenkins test ceph-volume allJenkins Jobs | Jenkins Jobs Definitionjenkins test windowsJenkins Job | Jenkins Job Definitionjenkins test rook e2eJenkins Job | Jenkins Job Definition