Skip to content
This repository has been archived by the owner on Feb 8, 2024. It is now read-only.

rgw_sal_motr: [CORTX-34181] allow multiparts with offline server #429

Merged
merged 12 commits into from
Sep 19, 2022

Conversation

andriytk
Copy link

@andriytk andriytk commented Sep 12, 2022

Currently, we create an additional index for each multipart-uploaded object to store its parts. If some server is down, the index creation operation would fail, thus failing the multipart upload.

Solution: don't create indexes on multipart uploads. Create an additional index to store objs parts when the bucket is created.

Closes #422.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox

Currently, we create an additional index for each multipart-
uploaded object to store its parts. If some server is down, the
index creation operation would fail, thus failing the multipart
upload.

Solution: don't create indexes on multipart uploads. Create an
additional index to store objs parts when the bucket is created.

Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
src/rgw/motr/gc/gc.cc Outdated Show resolved Hide resolved
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
src/rgw/rgw_sal_motr.cc Outdated Show resolved Hide resolved
src/rgw/rgw_sal_motr.cc Outdated Show resolved Hide resolved
src/rgw/motr/gc/gc.h Outdated Show resolved Hide resolved
andriytk and others added 5 commits September 14, 2022 10:46
Co-authored-by: Sumedh Anantrao Kulkarni <sumedh.a.kulkarni@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
@andriytk
Copy link
Author

andriytk commented Sep 15, 2022

Ran a smoke tests manually on my devvm setup (writing/reading/checking multipart uploaded object) with and without caching enabled - it seems working fine.

@sachitanands
Copy link

Hi @andriytk Could you please run Sanity ceph test suite with your PR.
https://eos-jenkins.colo.seagate.com/job/Cortx-Automation/job/S3Server/job/S3-Compatibility-Test-Ceph-RGW/

this is to make sure existing tests are not breaking.

@andriytk
Copy link
Author

test_multipart_upload_multiple_sizes has failed, trying to figure out the problem...

@andriytk
Copy link
Author

Reproduced:

$ aws s3 cp --endpoint-url http://localhost:8000 /tmp/10m+100k s3://testbucket0/10m+100k
upload failed: ../../tmp/10m+100k to s3://testbucket0/10m+100k An error occurred (InvalidPart) when calling the CompleteMultipartUpload operation: Unknown

src/rgw/rgw_sal_motr.cc Outdated Show resolved Hide resolved
Use key prefix when calling next_query_by_name() from bucket
multiparts index to avoid fetching not relevant parts.

Also, use the correct key at MotrGC::process_parts() when
deleting the parts from bucket multiparts index.

Signed-off-by: Andriy Tkachuk <andriy.tkachuk@seagate.com>
@andriytk
Copy link
Author

retest this please

1 similar comment
@andriytk
Copy link
Author

retest this please

@andriytk
Copy link
Author

retest this please

@andriytk
Copy link
Author

image

@andriytk andriytk merged commit 82dba61 into Seagate:main Sep 19, 2022
@andriytk andriytk deleted the no-index-per-mp-obj branch September 19, 2022 17:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multi-part uploads fail when some server is offline
6 participants